mirror of
https://github.com/SqrtMinusOne/dotfiles.git
synced 2025-12-10 19:23:03 +03:00
Compare commits
2 commits
b2d03efaf4
...
fbd9314bb7
| Author | SHA1 | Date | |
|---|---|---|---|
| fbd9314bb7 | |||
| 59e92e678f |
4 changed files with 34 additions and 32 deletions
|
|
@ -7753,7 +7753,7 @@ base toot."
|
||||||
(telega-webpage-chat-link :foreground (my/color-value 'base0)
|
(telega-webpage-chat-link :foreground (my/color-value 'base0)
|
||||||
:background (my/color-value 'fg)))
|
:background (my/color-value 'fg)))
|
||||||
:config
|
:config
|
||||||
(when (file-directory-p "~/.guix-extra-profiles/emacs/")
|
(when (file-exists-p "~/.guix-extra-profiles/emacs/emacs/bin/telega-server")
|
||||||
(setq telega-server-command
|
(setq telega-server-command
|
||||||
(expand-file-name
|
(expand-file-name
|
||||||
"~/.guix-extra-profiles/emacs/emacs/bin/telega-server")))
|
"~/.guix-extra-profiles/emacs/emacs/bin/telega-server")))
|
||||||
|
|
@ -8670,16 +8670,16 @@ Which creates the following output:
|
||||||
The functions also skips lines in [square brackets] and ones that
|
The functions also skips lines in [square brackets] and ones that
|
||||||
start with more than 3 spaces."
|
start with more than 3 spaces."
|
||||||
(when-let* ((lines (seq-filter
|
(when-let* ((lines (seq-filter
|
||||||
(lambda (s) (not (or (string-empty-p s)
|
(lambda (s) (not (or (string-empty-p s)
|
||||||
(string-match-p (rx bos "[" (* nonl) "]") s)
|
(string-match-p (rx bos "[" (* nonl) "]") s)
|
||||||
(string-match-p (rx bos (>= 3 " ")) s))))
|
(string-match-p (rx bos (>= 3 " ")) s))))
|
||||||
(split-string string "\n")))
|
(split-string string "\n")))
|
||||||
(first-line (car lines))
|
(first-line (car lines))
|
||||||
(headers (split-string first-line))
|
(headers (split-string first-line))
|
||||||
(header-indices (mapcar
|
(header-indices (mapcar
|
||||||
(lambda (header)
|
(lambda (header)
|
||||||
(cl-search header first-line))
|
(cl-search header first-line))
|
||||||
headers)))
|
headers)))
|
||||||
(cl-loop for line in (cdr lines)
|
(cl-loop for line in (cdr lines)
|
||||||
collect (cl-loop for header in headers
|
collect (cl-loop for header in headers
|
||||||
for start in header-indices
|
for start in header-indices
|
||||||
|
|
@ -8703,8 +8703,9 @@ The return value is a list of alists with the following keys:
|
||||||
collect `((path . ,(if (file-directory-p localpath)
|
collect `((path . ,(if (file-directory-p localpath)
|
||||||
(concat localpath "/")
|
(concat localpath "/")
|
||||||
localpath))
|
localpath))
|
||||||
(enabled . ,(string-equal (alist-get 'ACTIVE value)
|
(enabled . ,(seq-contains-p
|
||||||
"Enabled"))))))
|
'("Pending" "Loading" "Running")
|
||||||
|
(alist-get 'RUN_STATE value)))))))
|
||||||
|
|
||||||
(defun my/index--tree-get-paths (tree &optional kind)
|
(defun my/index--tree-get-paths (tree &optional kind)
|
||||||
"Get paths from TREE.
|
"Get paths from TREE.
|
||||||
|
|
@ -8746,7 +8747,7 @@ The return value is a list of commands as defined by
|
||||||
(append
|
(append
|
||||||
(cl-loop for path in (seq-difference mega-paths-to-enable mega-paths-enabled)
|
(cl-loop for path in (seq-difference mega-paths-to-enable mega-paths-enabled)
|
||||||
if (seq-contains-p mega-paths-disabled path)
|
if (seq-contains-p mega-paths-disabled path)
|
||||||
collect (list (format "mega-sync -e \"%s\"" path) "Mega enable sync" 5)
|
collect (list (format "mega-sync -r \"%s\"" path) "Mega enable sync" 5)
|
||||||
else append (list
|
else append (list
|
||||||
(list (format "mega-mkdir -p \"%s\""
|
(list (format "mega-mkdir -p \"%s\""
|
||||||
(my/index--mega-local-path path))
|
(my/index--mega-local-path path))
|
||||||
|
|
|
||||||
6
.profile
6
.profile
|
|
@ -52,10 +52,10 @@ fi
|
||||||
|
|
||||||
# [[file:Console.org::*ssh-agent][ssh-agent:1]]
|
# [[file:Console.org::*ssh-agent][ssh-agent:1]]
|
||||||
if ! pgrep -u "$USER" ssh-agent > /dev/null; then
|
if ! pgrep -u "$USER" ssh-agent > /dev/null; then
|
||||||
ssh-agent -t 1h > "$XDG_RUNTIME_DIR/ssh-agent.env"
|
ssh-agent -t 1h > "/tmp/ssh-agent.env"
|
||||||
fi
|
fi
|
||||||
if [[ ! -f "$SSH_AUTH_SOCK" ]]; then
|
if [[ ! -f "$SSH_AUTH_SOCK" ]]; then
|
||||||
source "$XDG_RUNTIME_DIR/ssh-agent.env" >/dev/null
|
source "/tmp/ssh-agent.env" >/dev/null
|
||||||
fi
|
fi
|
||||||
# ssh-agent:1 ends here
|
# ssh-agent:1 ends here
|
||||||
|
|
||||||
|
|
@ -69,7 +69,7 @@ if [ -z "$IS_ANDROID" ] && [ -z "$NO_GUIX" ] ; then
|
||||||
. "$GUIX_PROFILE"/etc/profile
|
. "$GUIX_PROFILE"/etc/profile
|
||||||
fi
|
fi
|
||||||
if [ -d "$profile"/share/man ]; then
|
if [ -d "$profile"/share/man ]; then
|
||||||
if command -v manpath; then
|
if command -v manpath >/dev/null 2>/dev/null; then
|
||||||
export MANPATH="${MANPATH:-$(manpath)}:$profile/share/man"
|
export MANPATH="${MANPATH:-$(manpath)}:$profile/share/man"
|
||||||
else
|
else
|
||||||
export MANPATH="${MANPATH}:$profile/share/man"
|
export MANPATH="${MANPATH}:$profile/share/man"
|
||||||
|
|
|
||||||
|
|
@ -129,7 +129,7 @@ if [ -z "$IS_ANDROID" ] && [ -z "$NO_GUIX" ] ; then
|
||||||
. "$GUIX_PROFILE"/etc/profile
|
. "$GUIX_PROFILE"/etc/profile
|
||||||
fi
|
fi
|
||||||
if [ -d "$profile"/share/man ]; then
|
if [ -d "$profile"/share/man ]; then
|
||||||
if command -v manpath; then
|
if command -v manpath >/dev/null 2>/dev/null; then
|
||||||
export MANPATH="${MANPATH:-$(manpath)}:$profile/share/man"
|
export MANPATH="${MANPATH:-$(manpath)}:$profile/share/man"
|
||||||
else
|
else
|
||||||
export MANPATH="${MANPATH}:$profile/share/man"
|
export MANPATH="${MANPATH}:$profile/share/man"
|
||||||
|
|
|
||||||
29
Emacs.org
29
Emacs.org
|
|
@ -10670,7 +10670,7 @@ Or you can load up Element for a moment to see what the mention was, if that's e
|
||||||
(telega-webpage-chat-link :foreground (my/color-value 'base0)
|
(telega-webpage-chat-link :foreground (my/color-value 'base0)
|
||||||
:background (my/color-value 'fg)))
|
:background (my/color-value 'fg)))
|
||||||
:config
|
:config
|
||||||
(when (file-directory-p "~/.guix-extra-profiles/emacs/")
|
(when (file-exists-p "~/.guix-extra-profiles/emacs/emacs/bin/telega-server")
|
||||||
(setq telega-server-command
|
(setq telega-server-command
|
||||||
(expand-file-name
|
(expand-file-name
|
||||||
"~/.guix-extra-profiles/emacs/emacs/bin/telega-server")))
|
"~/.guix-extra-profiles/emacs/emacs/bin/telega-server")))
|
||||||
|
|
@ -11943,16 +11943,16 @@ Which creates the following output:
|
||||||
The functions also skips lines in [square brackets] and ones that
|
The functions also skips lines in [square brackets] and ones that
|
||||||
start with more than 3 spaces."
|
start with more than 3 spaces."
|
||||||
(when-let* ((lines (seq-filter
|
(when-let* ((lines (seq-filter
|
||||||
(lambda (s) (not (or (string-empty-p s)
|
(lambda (s) (not (or (string-empty-p s)
|
||||||
(string-match-p (rx bos "[" (* nonl) "]") s)
|
(string-match-p (rx bos "[" (* nonl) "]") s)
|
||||||
(string-match-p (rx bos (>= 3 " ")) s))))
|
(string-match-p (rx bos (>= 3 " ")) s))))
|
||||||
(split-string string "\n")))
|
(split-string string "\n")))
|
||||||
(first-line (car lines))
|
(first-line (car lines))
|
||||||
(headers (split-string first-line))
|
(headers (split-string first-line))
|
||||||
(header-indices (mapcar
|
(header-indices (mapcar
|
||||||
(lambda (header)
|
(lambda (header)
|
||||||
(cl-search header first-line))
|
(cl-search header first-line))
|
||||||
headers)))
|
headers)))
|
||||||
(cl-loop for line in (cdr lines)
|
(cl-loop for line in (cdr lines)
|
||||||
collect (cl-loop for header in headers
|
collect (cl-loop for header in headers
|
||||||
for start in header-indices
|
for start in header-indices
|
||||||
|
|
@ -11979,8 +11979,9 @@ The return value is a list of alists with the following keys:
|
||||||
collect `((path . ,(if (file-directory-p localpath)
|
collect `((path . ,(if (file-directory-p localpath)
|
||||||
(concat localpath "/")
|
(concat localpath "/")
|
||||||
localpath))
|
localpath))
|
||||||
(enabled . ,(string-equal (alist-get 'ACTIVE value)
|
(enabled . ,(seq-contains-p
|
||||||
"Enabled"))))))
|
'("Pending" "Loading" "Running")
|
||||||
|
(alist-get 'RUN_STATE value)))))))
|
||||||
#+end_src
|
#+end_src
|
||||||
|
|
||||||
And get the same data from the tree.
|
And get the same data from the tree.
|
||||||
|
|
@ -12028,7 +12029,7 @@ The return value is a list of commands as defined by
|
||||||
(append
|
(append
|
||||||
(cl-loop for path in (seq-difference mega-paths-to-enable mega-paths-enabled)
|
(cl-loop for path in (seq-difference mega-paths-to-enable mega-paths-enabled)
|
||||||
if (seq-contains-p mega-paths-disabled path)
|
if (seq-contains-p mega-paths-disabled path)
|
||||||
collect (list (format "mega-sync -e \"%s\"" path) "Mega enable sync" 5)
|
collect (list (format "mega-sync -r \"%s\"" path) "Mega enable sync" 5)
|
||||||
else append (list
|
else append (list
|
||||||
(list (format "mega-mkdir -p \"%s\""
|
(list (format "mega-mkdir -p \"%s\""
|
||||||
(my/index--mega-local-path path))
|
(my/index--mega-local-path path))
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue