chore(git-bug): improve alias execution and refresh

Amolith created

Explicitly wrap git-bug aliases in `fish -c` to ensure correct shell
execution regardless of the default shell.

Update `git-bug-pull` to use `--git-common-dir` for improved
compatibility across different repository setups and automatically
refresh the bug cache after pulling new bugs.

Change summary

dot_config/git/config.tmpl                          | 4 ++--
dot_config/private_fish/functions/git-bug-pull.fish | 4 ++--
2 files changed, 4 insertions(+), 4 deletions(-)

Detailed changes

dot_config/git/config.tmpl 🔗

@@ -19,8 +19,8 @@
 	pl = pull
 	bugs = bug bug
 	create-bug = bug bug new
-	push-bugs = !git-bug-push
-	pull-bugs = !git-bug-pull
+	push-bugs = !fish -c 'git-bug-push'
+	pull-bugs = !fish -c 'git-bug-pull'
 [user]
 	name = Amolith
 	email = amolith@secluded.site

dot_config/private_fish/functions/git-bug-pull.fish 🔗

@@ -3,6 +3,6 @@ function git-bug-pull
     echo "fetching bugs from '$remote' remote..." >&2
     git fetch $remote "refs/bugs/*:refs/bugs/*" "refs/identities/*:refs/identities/*"
 
-    set git_dir (git rev-parse --git-dir)
-    test -d $git_dir/git-bug/cache/; and rm -rf $git_dir/git-bug/cache/
+    set git_dir (git rev-parse --git-common-dir)
+    test -d $git_dir/git-bug/cache/; and rm -rf $git_dir/git-bug/cache/; and git bug bug
 end