mirror of
https://github.com/Xevion/dotfiles.git
synced 2026-01-31 10:24:12 -06:00
config: add JetBrains Toolbox and GitHub CLI completions
- Add JetBrains Toolbox scripts directory to PATH across shells - Initialize GitHub CLI completions in bash, fish, and PowerShell - Lazy-load gh completions in Fish to improve startup time
This commit is contained in:
@@ -0,0 +1,18 @@
|
||||
# Lazy-load gh completions on first use
|
||||
function gh --wraps gh
|
||||
# Initialize gh completions only once
|
||||
if not set -q __gh_initialized
|
||||
set -g __gh_initialized 1
|
||||
|
||||
# Generate and source completions
|
||||
if command -q gh
|
||||
command gh completion -s fish | source
|
||||
else
|
||||
echo "gh is not installed" >&2
|
||||
return 1
|
||||
end
|
||||
end
|
||||
|
||||
# Execute the actual gh command
|
||||
command gh $argv
|
||||
end
|
||||
Reference in New Issue
Block a user