diff options
Diffstat (limited to 'git-gpgcrypt')
-rwxr-xr-x | git-gpgcrypt | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/git-gpgcrypt b/git-gpgcrypt index caef5bc..1bd0a90 100755 --- a/git-gpgcrypt +++ b/git-gpgcrypt @@ -39,6 +39,12 @@ init() { echo "directory and run 'git checkout .', or )" else setup_filters + # Plain "git checkout -f ." works on all systems except Arch, where + # if fails to re-checkout already existing files. So, remove them + # first, taking care to not remove special files. + find . -type f | grep -v -E "^(\./\.(git|gpg))" | xargs --no-run-if-empty -n 20 rm + # After filters have been set up, force re-checkout of all files to + # decrypt them. git checkout -f . echo "Initialized a clone" fi |