diff options
Diffstat (limited to 'pass/install.sh')
-rwxr-xr-x | pass/install.sh | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/pass/install.sh b/pass/install.sh index f91caf4..54d1b8d 100755 --- a/pass/install.sh +++ b/pass/install.sh @@ -16,7 +16,9 @@ if [ ! -d "$store" ]; then else printf "%s: Syncing password-store\n" "$0" - git -C "$store" remote update origin + if [ "$(date "+%s" -r "$store"/.git/FETCH_HEAD)" -lt "$(date +%s --date="12 hour ago")" ]; then + git -C "$store" remote update origin + fi LOCAL=$(git -C "$store" rev-parse @) REMOTE=$(git -C "$store" rev-parse '@{u}') |