aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEuAndreh <eu@euandre.org>2022-12-02 16:19:10 -0300
committerEuAndreh <eu@euandre.org>2022-12-02 16:19:10 -0300
commit8a02114a85ad5a12662970a38ff27a1082730e46 (patch)
tree9bc4b31d365fd70c942d71c3a55b3a8ac14c567a
parentetc/i3/config: Show desktop notification after taking screenshot (diff)
downloaddotfiles-8a02114a85ad5a12662970a38ff27a1082730e46.tar.gz
dotfiles-8a02114a85ad5a12662970a38ff27a1082730e46.tar.xz
etc/guix/home.scm: Move custom built packages to shell aliases
-rw-r--r--etc/guix/home.scm40
-rw-r--r--etc/sh/rc3
2 files changed, 6 insertions, 37 deletions
diff --git a/etc/guix/home.scm b/etc/guix/home.scm
index 3d4d255..5c81aaf 100644
--- a/etc/guix/home.scm
+++ b/etc/guix/home.scm
@@ -130,43 +130,9 @@
'("GPODDER_DOWNLOAD_DIR" = ("${XDG_DOWNLOAD_DIR:-$HOME/Downloads}/gPodder"))))
'("gpo" "gpodder")))))))))))
-(define (with-options pkg bin opts)
- (package
- (inherit pkg)
- (arguments
- (substitute-keyword-arguments (package-arguments pkg)
- ((#:phases phases '%standard-phases)
- `(modify-phases ,phases
- (add-after 'install 'wrap-with-flags
- (lambda* (#:key outputs #:allow-other-keys)
- (define (wrap-options prog options)
- (let ((wrapped-file (string-append (dirname prog) "/." (basename prog) "-orig")))
- (rename-file prog wrapped-file)
- (call-with-output-file prog
- (lambda (port)
- (format port
- "#!/bin/sh~%~%exec \"~a\" ~a \"$@\"~%"
- (canonicalize-path wrapped-file)
- options)))
- (chmod prog #o755)))
- (wrap-options (string-append (assoc-ref outputs "out")
- "/bin/"
- ,bin)
- ,opts)))))))))
-
-(define wget-with-options
- (with-options wget "wget" "--hsts-file=\"$XDG_STATE_HOME\"/wget-hsts"))
-
-(define tmux-with-options
- (with-options tmux "tmux" "-f \"$XDG_CONFIG_HOME\"/tmux/tmux.conf"))
-
-(define texinfo-with-options
- (with-options texinfo "info" "--init-file \"$XDG_CONFIG_HOME\"/info/infokey"))
-
(define (xdg-config-home s)
(string-append (getenv "XDG_CONFIG_HOME") "/" s))
-
(define (slurp name)
(string-trim-both
(call-with-input-file
@@ -270,6 +236,9 @@
cssc
quilt
+ wget
+ tmux
+ texinfo
gnupg
rsync
tree
@@ -557,9 +526,6 @@
icedove
firefox))
(list ;; cmucl
- wget-with-options
- tmux-with-options
- texinfo-with-options
hunspell-iconv
gpodder-xdg
(hunspell-dictionary-utf8 "en")
diff --git a/etc/sh/rc b/etc/sh/rc
index 9cd9eef..a443587 100644
--- a/etc/sh/rc
+++ b/etc/sh/rc
@@ -134,6 +134,9 @@ alias bc='bc -l'
alias sqlite='rlwrap sqlite3'
alias guile='guile -l "$XDG_CONFIG_HOME"/guile/init.scm'
+alias info='info --init-file "$XDG_CONFIG_HOME"/info/infokey'
+alias wget='wget --hsts-file="$XDG_STATE_HOME"/wget-hsts'
+alias tmux='tmux -f "$XDG_CONFIG_HOME"/tmux/tmux.conf'
alias flush='sync && echo 3 | sudo tee /proc/sys/vm/drop_caches > /dev/null'
alias kal='khal calendar today `LANG=en.UTF-8 date +%A`'