mirror of https://codeberg.org/anemofilia/zero
home-environments: radio: Add more fish abbreviations
parent
f7563fff85
commit
5a3ddf0fa5
|
@ -3,7 +3,7 @@
|
||||||
#|M|# #:use-module (ice-9 match)
|
#|M|# #:use-module (ice-9 match)
|
||||||
|
|
||||||
#|GNU|#
|
#|GNU|#
|
||||||
#| |# #:use-module (gnu)
|
#|•|# #:use-module (gnu)
|
||||||
#|H|# #:use-module ((gnu home) #:select (this-home-environment))
|
#|H|# #:use-module ((gnu home) #:select (this-home-environment))
|
||||||
#|H|# #:use-module ((gnu home) #:hide (this-home-environment)
|
#|H|# #:use-module ((gnu home) #:hide (this-home-environment)
|
||||||
#:prefix user-)
|
#:prefix user-)
|
||||||
|
@ -46,7 +46,7 @@
|
||||||
#:use-module (gnu packages xorg)
|
#:use-module (gnu packages xorg)
|
||||||
|
|
||||||
#|GNU home services|#
|
#|GNU home services|#
|
||||||
#| |# #:use-module (gnu home services)
|
#|•|# #:use-module (gnu home services)
|
||||||
#|D|# #:use-module (gnu home services desktop)
|
#|D|# #:use-module (gnu home services desktop)
|
||||||
#:use-module (gnu home services dotfiles)
|
#:use-module (gnu home services dotfiles)
|
||||||
#|G|# #:use-module (gnu home services guix)
|
#|G|# #:use-module (gnu home services guix)
|
||||||
|
@ -71,7 +71,7 @@
|
||||||
#|W|# #:use-module (radix packages wm)
|
#|W|# #:use-module (radix packages wm)
|
||||||
|
|
||||||
#|Radix home services|#
|
#|Radix home services|#
|
||||||
#| |# #:use-module (radix home services)
|
#|•|# #:use-module (radix home services)
|
||||||
#|G|# #:use-module (radix home services gnupg)
|
#|G|# #:use-module (radix home services gnupg)
|
||||||
#|S|# #:use-module (radix home services shells)
|
#|S|# #:use-module (radix home services shells)
|
||||||
#|X|# #:use-module (radix home services xdg)
|
#|X|# #:use-module (radix home services xdg)
|
||||||
|
@ -259,78 +259,93 @@
|
||||||
("':e'" . "kak")
|
("':e'" . "kak")
|
||||||
("':q'" . "exit")))
|
("':q'" . "exit")))
|
||||||
(abbreviations
|
(abbreviations
|
||||||
(let ((at (symbol-prefix-proc '@))
|
(let ((@ (symbol-prefix-proc '@))
|
||||||
(edit (partial string-append "$EDITOR ")))
|
(edit (partial format #f "$EDITOR~@{ ~a~}"))
|
||||||
(append
|
(@radix (partial symbol-append '~/areas/code/scm/radix))
|
||||||
(map (match-lambda
|
(@zero (partial symbol-append '~/areas/code/scm/zero)))
|
||||||
((x . y) (abbreviation
|
`(,@(map (match-lambda
|
||||||
(name (at x))
|
((x . y) (abbreviation
|
||||||
(position 'anywhere)
|
(name (@ x))
|
||||||
(expansion (y x)))))
|
(position 'anywhere)
|
||||||
(associate-right
|
(expansion (y x)))))
|
||||||
#|P.A.R.A.|#
|
(associate-right
|
||||||
((lambda (dir)
|
#|P.A.R.A.|#
|
||||||
(if (equal? dir 'archive)
|
((lambda (dir)
|
||||||
(symbol-append '~/. dir)
|
(cond ((equal? dir 'archive)
|
||||||
(symbol-append '~/ dir)))
|
(symbol-append '~/. dir))
|
||||||
'(areas projects resources resources/bookmarks archive))
|
((equal? dir 'bookmarks)
|
||||||
|
(symbol-append '~/resources/ dir))
|
||||||
|
(else (symbol-append '~/ dir))))
|
||||||
|
'(areas bookmarks projects resources archive))
|
||||||
|
|
||||||
#|XDG user directories|#
|
#|XDG user directories|#
|
||||||
((const (fish-function "xdg-user-directory"))
|
((const (fish-function "xdg-user-directory"))
|
||||||
'(desktop documents download music pictures videos))
|
'(desktop documents download music pictures videos))
|
||||||
|
|
||||||
#|Code projects|#
|
#|Code projects|#
|
||||||
((symbol-prefix-proc '~/projects/code/)
|
((symbol-prefix-proc '~/projects/code/)
|
||||||
'(c clj cpp hs html kak md pl scm sh tex zig))
|
'(c clj cpp hs html kak md pl scm sh tex zig))
|
||||||
|
|
||||||
#|Guix channels|#
|
#|Code areas|#
|
||||||
((symbol-prefix-proc '~/projects/code/scm/)
|
((symbol-prefix-proc '~/areas/code/scm/)
|
||||||
'(ajatt guix radix zero))
|
'(guix radix zero))
|
||||||
|
|
||||||
#|Configuration|#
|
#|Radix|#
|
||||||
((symbol-prefix-proc
|
((partial @radix '/radix/)
|
||||||
'~/areas/code/scm/radix/operating-system/)
|
'(packages services home/services))
|
||||||
(list (string->symbol (gethostname))))
|
|
||||||
((symbol-prefix-proc
|
|
||||||
'~/areas/code/scm/radix/home-environments/)
|
|
||||||
(list (string->symbol (getlogin))))))
|
|
||||||
|
|
||||||
(map (match-lambda
|
#|Zero|#
|
||||||
((x . y) (abbreviation
|
((partial @zero '/operating-systems/)
|
||||||
(name x)
|
'(buer))
|
||||||
(expansion y))))
|
((partial @zero '/home-environments/)
|
||||||
`(#|Download/Upload|#
|
'(radio))
|
||||||
(a . "aria2c -j 10 '%'")
|
((partial @zero '/home-environments/radio/)
|
||||||
(i . "ipfs get %")
|
'(files))
|
||||||
(m . "yt-dlp --prefer-free-formats -x '%'")
|
|
||||||
(v . "yt-dlp --prefer-free-formats '%'")
|
|
||||||
(z . "curl -F file=@% https://0x0.st | xsel -b")))
|
|
||||||
|
|
||||||
(map (match-lambda
|
#|Configuration|#
|
||||||
((x . y) (abbreviation
|
((symbol-prefix-proc
|
||||||
(name x)
|
'~/areas/code/scm/radix/operating-system/)
|
||||||
(position 'anywhere)
|
(list (string->symbol (gethostname))))
|
||||||
(expansion y))))
|
((symbol-prefix-proc
|
||||||
`(#|Shell history|#
|
'~/areas/code/scm/radix/home-environments/)
|
||||||
(!! . ,(fish-function "bang-bang"))
|
(list (string->symbol (getlogin))))))
|
||||||
(!$ . ,(fish-function "bang-dollar"))
|
|
||||||
(!* . ,(fish-function "bang-star"))
|
|
||||||
|
|
||||||
#|Guix|#
|
,@(map (match-lambda
|
||||||
(!dgen . "guix % delete-generations 2w")
|
((x . y) (abbreviation
|
||||||
(!repair . "doas guix build --repair")
|
(name x)
|
||||||
(!pull . "guix pull")
|
(expansion y))))
|
||||||
(!home . "guix home reconfigure ~/.config/guix/home.scm")
|
`(#|Download/Upload|#
|
||||||
(!system . "doas guix system reconfigure /etc/config.scm")
|
(a . "aria2c -j 10 '%'")
|
||||||
|
(i . "ipfs get %")
|
||||||
|
(m . "yt-dlp --prefer-free-formats -x '%'")
|
||||||
|
(v . "yt-dlp --prefer-free-formats '%'")
|
||||||
|
(z . "curl -F file=@% https://0x0.st | xsel -b")))
|
||||||
|
|
||||||
#|Processes|#
|
,@(map (match-lambda
|
||||||
(tf . "setsid -f %>/dev/null 2>&1 & disown")
|
((x . y) (abbreviation
|
||||||
|
(name x)
|
||||||
|
(position 'anywhere)
|
||||||
|
(expansion y))))
|
||||||
|
`(#|Shell history|#
|
||||||
|
(!! . ,(fish-function "bang-bang"))
|
||||||
|
(!$ . ,(fish-function "bang-dollar"))
|
||||||
|
(!* . ,(fish-function "bang-star"))
|
||||||
|
|
||||||
#|Quick edit|#
|
#|Guix|#
|
||||||
(:e . ,(edit))
|
(!dgen . "guix % delete-generations 2w")
|
||||||
(:system . ,(edit "/etc/config.scm"))
|
(!repair . "doas guix build --repair")
|
||||||
(:home . ,(edit "~/.config/guix/home.scm"))
|
(!pull . "guix pull")
|
||||||
(:todo . ,(edit "~/areas/meta/todo")))))))))
|
(!home . "guix home reconfigure ~/.config/guix/home.scm")
|
||||||
|
(!system . "doas guix system reconfigure /etc/config.scm")
|
||||||
|
|
||||||
|
#|Processes|#
|
||||||
|
(tf . "setsid -f %>/dev/null 2>&1 & disown")
|
||||||
|
|
||||||
|
#|Quick edit|#
|
||||||
|
(:e . ,(edit))
|
||||||
|
(:system . ,(edit "/etc/config.scm"))
|
||||||
|
(:home . ,(edit "~/.config/guix/home.scm"))
|
||||||
|
(:todo . ,(edit "~/areas/meta/todo")))))))))
|
||||||
|
|
||||||
#|Environment variables services|#
|
#|Environment variables services|#
|
||||||
(simple-service 'shell-environment-variables
|
(simple-service 'shell-environment-variables
|
||||||
|
@ -346,7 +361,11 @@
|
||||||
("GUILE_LOAD_PATH"
|
("GUILE_LOAD_PATH"
|
||||||
. ,(format #f "~?~?"
|
. ,(format #f "~?~?"
|
||||||
"~@{:$HOME/areas/code/scm/~a~}"
|
"~@{:$HOME/areas/code/scm/~a~}"
|
||||||
'(ajatt radix zero)
|
'(ajatt
|
||||||
|
radix
|
||||||
|
zero
|
||||||
|
zero/operating-systems
|
||||||
|
zero/home-environments)
|
||||||
"~@{:~a/share/guile/site/3.0~}"
|
"~@{:~a/share/guile/site/3.0~}"
|
||||||
'($HOME/.guix-home/profile
|
'($HOME/.guix-home/profile
|
||||||
$XDG_CONFIG_HOME/guix/current
|
$XDG_CONFIG_HOME/guix/current
|
||||||
|
|
Loading…
Reference in New Issue