Skip to content

Commit e66cc5a

Browse files
committed
Bug fixed --sign option.
* Updated tests with sign option support.
1 parent 85baf12 commit e66cc5a

File tree

2 files changed

+2
-4
lines changed

2 files changed

+2
-4
lines changed

history-sync.plugin.zsh

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -220,9 +220,7 @@ function history_sync_push() {
220220
else
221221
sign='y'
222222
fi
223-
fi
224223

225-
if [[ -n "$sign" ]]; then
226224
case "$sign" in
227225
[Yy]* )
228226
ENCRYPT_CMD+="--sign "

test/test.zsh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ info "TEST SYNC HISTORY BASIC 0"
7878
setup
7979
RAND=$RANDOM
8080
echo "1 echo $RAND" >> ~/.zsh_history
81-
echo "$UID" | zhps -y && zhpl -y
81+
zhps -y -r $UID && zhpl -y
8282
check_history "^1 echo $RAND$"
8383
success "SUCCESS"
8484

@@ -94,7 +94,7 @@ echo "2 echo $RAND1" >> ~/.zsh_history
9494
echo "3 echo $RAND2" >> ~/.zsh_history
9595
echo "4 echo $RAND3" >> ~/.zsh_history
9696
echo "5 echo $RAND4" >> ~/.zsh_history
97-
zhps -y -r $UID && zhpl -y
97+
zhps -y -r $UID -s $UID && zhpl -y
9898
check_history "^1 echo $RAND0$"
9999
check_history "^2 echo $RAND1$"
100100
check_history "^3 echo $RAND2$"

0 commit comments

Comments
 (0)