forked from p96170835/amis
有修改内容时,可以按 y 继续执行
This commit is contained in:
parent
1a2d716951
commit
f04f15f767
|
@ -6,8 +6,13 @@ if [ -z "$(git status --porcelain)" ]; then
|
|||
echo "Working directory clean"
|
||||
else
|
||||
# Uncommitted changes
|
||||
echo "Skiped: You got uncommitted changes"
|
||||
exit
|
||||
read -p "You got uncommitted changes, press y to continue? " -n 1 -r
|
||||
echo # (optional) move to a new line
|
||||
if [[ ! $REPLY =~ ^[Yy]$ ]]
|
||||
then
|
||||
echo "Skiped!"
|
||||
[[ "$0" = "$BASH_SOURCE" ]] && exit 1 || return 1 # handle exits from shell or function but don't exit interactive shell
|
||||
fi
|
||||
fi
|
||||
|
||||
rm -rf gh-pages
|
||||
|
|
Loading…
Reference in New Issue