Adam Brown / gitlabfred · GitLab
·2 min
Adam Brown authored
| Name | Last commit | Last update |
|---|
Alfred GitLabFred #
Helpful GitLab assistant for Alfred
Usage #
- Search repositories (public only without GitLab Token set) via the keyword
glab.- ⏎: Open the repo’s GitLab page.
- ⌘C: Copy the repo URL.
- ⌃⏎: Clone the repo to a local folder and open in the Terminal.
- ⌥⏎: Fork the repo & clone the fork to a local folder. Then open in Terminal.
- Access merge requests you have opened with keyword
glabmr.- ⏎: Open the MR in the browser.
- ⌘C: Copy the MR URL.
- Open recent GitLab issues you are involved in with
glabi.- ⏎: Open the issue in the browser.
- ⌘C: Copy the issue URL.
- Access your GitLab todos list with keyword
glabt.- ⏎: Open the todo in the browser.
- ⌃⏎: Mark the todo as done.
- ⌘C: Copy the issue URL.
The glab prefix can be changed in the configuration page, thus affecting all the keywords.
GitLab Token #
- Add the GitLab Token in the Alfred workflow configuration.
- Or: export the token in your
.zshenv.
# add this to your \`$HOME/.zshenv\`
# ($alfred_workflow_name is only populated by shell processes that called by Alfred)
if [[ "$alfred_workflow_name" == "GitLabFred" ]]; then
# if using a password manager, you can do something like this
# (\`op\` being the CLI for 1Password)
GITLAB_TOKEN=$(op plugin run -- glab config get token)
export GITLAB_TOKEN
fi