.nh .TH "glab" "1" "Apr 2024" "Auto generated by spf13/cobra" "" .SH NAME .PP glab-completion - Generate shell completion scripts .SH SYNOPSIS .PP \fBglab completion [flags]\fP .SH DESCRIPTION .PP The output of this command will be computer code and is meant to be saved to a file or immediately evaluated by an interactive shell. To load completions: .SS Bash .PP To load completions in your current shell session: .PP .RS .nf source <(glab completion -s bash) .fi .RE .PP To load completions for every new session, execute once: .SS Linux .PP .RS .nf glab completion -s bash > /etc/bash_completion.d/glab .fi .RE .SS macOS .PP .RS .nf glab completion -s bash > /usr/local/etc/bash_completion.d/glab .fi .RE .SS Zsh .PP If shell completion is not already enabled in your environment you will need to enable it. You can execute the following once: .PP .RS .nf echo "autoload -U compinit; compinit" >> ~/.zshrc .fi .RE .PP To load completions in your current shell session: .PP .RS .nf source <(glab completion -s zsh); compdef _glab glab .fi .RE .PP To load completions for every new session, execute once: .SS Linux .PP .RS .nf glab completion -s zsh > "${fpath[1]}/_glab" .fi .RE .SS macOS .PP For older versions of macOS, this may be required: .PP .RS .nf glab completion -s zsh > /usr/local/share/zsh/site-functions/_glab .fi .RE .PP The Homebrew version of glab should automatically install completions. .SS fish .PP To load completions in your current shell session: .PP .RS .nf glab completion -s fish | source .fi .RE .PP To load completions for every new session, execute once: .PP .RS .nf glab completion -s fish > ~/.config/fish/completions/glab.fish .fi .RE .SS PowerShell .PP To load completions in your current shell session: .PP .RS .nf glab completion -s powershell | Out-String | Invoke-Expression .fi .RE .PP To load completions for every new session, add the output of the above command to your PowerShell profile. .PP When installing glab through a package manager, however, it's possible that no additional shell configuration is necessary to gain completion support. For Homebrew, see https://docs.brew.sh/Shell-Completion \[la]https://docs.brew.sh/Shell-Completion\[ra] .SH OPTIONS .PP \fB--no-desc\fP[=false] Do not include shell completion description .PP \fB-s\fP, \fB--shell\fP="bash" Shell type: {bash|zsh|fish|powershell} .SH OPTIONS INHERITED FROM PARENT COMMANDS .PP \fB--help\fP[=false] Show help for command .SH SEE ALSO .PP \fBglab(1)\fP