Use 'git checkout HEAD' instead of reset+checkout.
Thanks for the suggestion to Jonathan Callen.
This commit is contained in:
parent
671838fee9
commit
0dca83a452
@ -174,8 +174,7 @@ check_for_changes() {
|
||||
# Discard any changes to a particular set of files.
|
||||
vcs_reset() {
|
||||
if [ ${SC_VCS%-svn} = git ]; then
|
||||
req git reset -q HEAD -- "${@}"
|
||||
git checkout -f -- "${@}" 2>/dev/null || req rm -f -- "${@}"
|
||||
git checkout HEAD -- "${@}" 2>/dev/null || req rm -f -- "${@}"
|
||||
elif [ ${SC_VCS} = svn ]; then
|
||||
req rm -f -- "${@}"
|
||||
svn revert -- "${@}" >/dev/null
|
||||
|
Loading…
Reference in New Issue
Block a user