Commit 80d6fbe6024ea66573a1490b786f11df2a5ab2ea
1 parent
3aa0d2d8a3
Add another test plugin to the testing system.
Showing 1 changed file with 18 additions and 6 deletions Side-by-side Diff
tests/.zshenv
... | ... | @@ -14,16 +14,28 @@ export PLUGIN_DIR="$PWD/test-plugin" |
14 | 14 | mkdir "$PLUGIN_DIR" |
15 | 15 | |
16 | 16 | # A wrapper function over `git` to work with the test plugin repo. |
17 | -pg () { | |
18 | - git --git-dir "$PLUGIN_DIR"/.git --work-tree "$PLUGIN_DIR" "$@" | |
19 | -} | |
17 | +alias pg='git --git-dir "$PLUGIN_DIR/.git" --work-tree "$PLUGIN_DIR"' | |
20 | 18 | |
21 | -cat > "$PLUGIN_DIR"/aliases.zsh <<EOF | |
22 | -alias hehe='echo hehe' | |
23 | -EOF | |
19 | +echo 'alias hehe="echo hehe"' > "$PLUGIN_DIR"/aliases.zsh | |
24 | 20 | |
25 | 21 | { |
26 | 22 | pg init |
27 | 23 | pg add . |
28 | 24 | pg commit -m 'Initial commit' |
29 | 25 | } > /dev/null |
26 | + | |
27 | +# Another test plugin. | |
28 | + | |
29 | +export PLUGIN_DIR2="$PWD/test-plugin2" | |
30 | +mkdir "$PLUGIN_DIR2" | |
31 | + | |
32 | +# A wrapper function over `git` to work with the test plugin repo. | |
33 | +alias pg2='git --git-dir "$PLUGIN_DIR2/.git" --work-tree "$PLUGIN_DIR2"' | |
34 | + | |
35 | +echo 'alias hehe="echo hehe2"' > "$PLUGIN_DIR2"/aliases.zsh | |
36 | + | |
37 | +{ | |
38 | + pg2 init | |
39 | + pg2 add . | |
40 | + pg2 commit -m 'Initial commit' | |
41 | +} > /dev/null |