Skip to content

Commit

Permalink
emacs: termux
Browse files Browse the repository at this point in the history
  • Loading branch information
SqrtMinusOne committed May 22, 2024
1 parent 4ba6e87 commit 6866ac5
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions .emacs.d/init.el
Original file line number Diff line number Diff line change
Expand Up @@ -379,7 +379,7 @@ then it takes a second \\[keyboard-quit] to abort the minibuffer."
(global-set-key (kbd "C-+") 'my/zoom-in)
(global-set-key (kbd "C-=") 'my/zoom-out)

(when my/is-termux
(when (and my/is-termux (not (equal (my/system-name) "snow")))
(define-key key-translation-map (kbd "`") (kbd "<escape>"))
(define-key key-translation-map (kbd "<escape>") (kbd "`")))

Expand Down Expand Up @@ -2555,6 +2555,7 @@ Returns (<buffer> . <workspace-index>) or nil."
(defun my/ltex-need-p ()
(let ((file-name (buffer-file-name)))
(cond
(my/is-termux nil)
((null file-name) nil)
((string-match-p (rx "/home/pavel/" (+ alnum) ".org" eos) file-name) nil)
((string-match-p (rx (literal org-directory) "/" (or "roam" "inbox-notes" "literature-notes" "journal")) file-name) t)
Expand Down Expand Up @@ -7859,7 +7860,6 @@ base toot."

(use-package ellama
:straight t
:if (not my/is-termux)
:init
(setq ellama-language "English")
:config
Expand Down
4 changes: 2 additions & 2 deletions Emacs.org
Original file line number Diff line number Diff line change
Expand Up @@ -680,7 +680,7 @@ Evil does a pretty good job of abstracting all these packages with a set of vim-
For some reason my ONYX device has the tilde and escape wrong.

#+begin_src emacs-lisp
(when my/is-termux
(when (and my/is-termux (not (equal (my/system-name) "snow")))
(define-key key-translation-map (kbd "`") (kbd "<escape>"))
(define-key key-translation-map (kbd "<escape>") (kbd "`")))
#+end_src
Expand Down Expand Up @@ -3505,6 +3505,7 @@ Check whether it's necessary to run LTeX:
(defun my/ltex-need-p ()
(let ((file-name (buffer-file-name)))
(cond
(my/is-termux nil)
((null file-name) nil)
((string-match-p (rx "/home/pavel/" (+ alnum) ".org" eos) file-name) nil)
((string-match-p (rx (literal org-directory) "/" (or "roam" "inbox-notes" "literature-notes" "journal")) file-name) t)
Expand Down Expand Up @@ -10795,7 +10796,6 @@ I don't have access to any proprietary APIs, but LLaMA 3 8b with [[https://ollam
#+begin_src emacs-lisp
(use-package ellama
:straight t
:if (not my/is-termux)
:init
(setq ellama-language "English")
:config
Expand Down

0 comments on commit 6866ac5

Please sign in to comment.