File tree Expand file tree Collapse file tree 3 files changed +16
-3
lines changed Expand file tree Collapse file tree 3 files changed +16
-3
lines changed Original file line number Diff line number Diff line change 1
1
# shellcheck shell=bash
2
2
cite ' about-alias'
3
- about-alias ' git aliases from oh-my-zsh'
3
+ about-alias ' git aliases from oh-my-zsh (incompatible with regular git aliases option) '
4
4
5
- # We are not vendoring this, as we need to adapt it to bash :(
5
+ if [[ -n $_bash_it_git_aliases_enabled ]]; then
6
+ _log_error " git-omz aliases are incompatible with regular git aliases"
7
+ return
8
+ fi
6
9
7
10
# Load after regular git aliases
8
11
# BASH_IT_LOAD_PRIORITY: 160
Original file line number Diff line number Diff line change 2
2
cite ' about-alias'
3
3
about-alias ' common git abbreviations'
4
4
5
+ # We can use this variable to make sure that we don't accidentally clash with git-zsh aliases
6
+ _bash_it_git_aliases_enabled=true
7
+
5
8
alias g=' git'
6
9
alias get=' git'
7
10
Original file line number Diff line number Diff line change @@ -39,7 +39,14 @@ function local_teardown {
39
39
40
40
@test " search: git" {
41
41
run _bash-it-search ' git' --no-color
42
- assert_line -n 0 ' aliases: git gitsvn '
42
+
43
+ assert_line -n 0 -p ' aliases:'
44
+ for alias in ' git' ' gitsvn' ' git-omz'
45
+ do
46
+ echo $alias
47
+ assert_line -n 0 -p $alias
48
+ done
49
+
43
50
assert_line -n 1 -p ' plugins:'
44
51
for plugin in " autojump" " git" " gitstatus" " git-subrepo" " jgitflow" " jump"
45
52
do
You can’t perform that action at this time.
0 commit comments