summaryrefslogtreecommitdiff
path: root/dotfiles/system/.profile.d
diff options
context:
space:
mode:
authorCraig Jennings <c@cjennings.net>2025-11-21 05:06:54 -0800
committerCraig Jennings <c@cjennings.net>2025-11-21 05:06:54 -0800
commitaa43e4e1c78ed92e45c4d7f8cc83a8bb558f43e7 (patch)
tree4267b184ec8dbd9fbde8f3a095d27361449c6a6b /dotfiles/system/.profile.d
parent7a0a806df05d573cf7969c9a2d80a1a49881d95a (diff)
session: dotfiles sync and GPG/Emacs auth debugging
Synced various dotfile configs (calibre, audacious, profile.d, xinitrc). Diagnosed and fixed Emacs/GPG auth issue by disabling systemd emacs.service which lacked DISPLAY environment for pinentry-dmenu.
Diffstat (limited to 'dotfiles/system/.profile.d')
-rw-r--r--dotfiles/system/.profile.d/fzf.sh19
-rwxr-xr-x[-rw-r--r--]dotfiles/system/.profile.d/zoxide.sh2
2 files changed, 17 insertions, 4 deletions
diff --git a/dotfiles/system/.profile.d/fzf.sh b/dotfiles/system/.profile.d/fzf.sh
index bd26d02..5fab752 100644
--- a/dotfiles/system/.profile.d/fzf.sh
+++ b/dotfiles/system/.profile.d/fzf.sh
@@ -13,6 +13,10 @@ export FZF_DEFAULT_COMMAND='rg --files'
export FZF_CTRL_T_COMMAND="$FZF_DEFAULT_COMMAND"
export FZF_DEFAULT_COMMAND='rg --files --no-ignore-vcs --hidden'
+# Directory paths for convenience functions
+IF_GAMES_DIR="$HOME/sync/org/text.games"
+BOOKS_DIR="$HOME/sync/books"
+
### NAVIGATION
# cdff - change directory find file
@@ -67,12 +71,21 @@ fif() {
### CONVENIENCE
-# Find a book in the calibre library and open it in emacs client.
+# Find an epub book in the library and open it in epr terminal reader.
# previously: find ~/books \( -iname \*.epub -o -iname \*.pdf -o -iname \*.djvu \) | fzf | xargs emacs
bk() {
- bkfile=$(find ~/sync/books/ \( -iname "*.pdf" -o -iname "*.epub" -o -iname "*.djvu" \) -print | fzf)
+ bkfile=$(find "$BOOKS_DIR" -iname "*.epub" -print | fzf)
if [ -n "$bkfile" ]; then
- emacsclient -c -a '' "$bkfile" &
+ epr "$bkfile"
+ fi
+}
+
+# Find an interactive fiction game and open it in frotz.
+# Supports Z-machine files (.z1-.z8, .zblorb, .blorb)
+tg() {
+ gamefile=$(find "$IF_GAMES_DIR" -type f \( -iname "*.z[1-8]" -o -iname "*.zblorb" -o -iname "*.blorb" \) -print | fzf)
+ if [ -n "$gamefile" ]; then
+ frotz "$gamefile"
fi
}
diff --git a/dotfiles/system/.profile.d/zoxide.sh b/dotfiles/system/.profile.d/zoxide.sh
index a748043..8bbb86b 100644..100755
--- a/dotfiles/system/.profile.d/zoxide.sh
+++ b/dotfiles/system/.profile.d/zoxide.sh
@@ -8,4 +8,4 @@
eval "$(zoxide init zsh)"
# Alias cd to use zoxide
-alias cd="z"
+# alias cd="z"