Skip to content

Use environment variables #4

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion git.plugin.zsh
Original file line number Diff line number Diff line change
Expand Up @@ -261,7 +261,11 @@ function git_count_all() {

# List all git aliases from the README:
function git_list_aliases() {
filename=~/.oh-my-zsh/custom/plugins/git/README.md
# if ZSH_CUSTOM is not set, use the default location:
if [[ -z $ZSH_CUSTOM ]]; then
ZSH_CUSTOM=${ZSH}/custom
fi
filename=${ZSH_CUSTOM}/plugins/git/README.md
from=$(grep -Fno '| **g** ' ${filename} | cut -f1 -d:)
stop=$(grep -no ' ' ${filename} | cut -f1 -d:)
to=$((stop - 2))
Expand Down