backup.sh: se etter git før vi kjører git
This commit is contained in:
@@ -18,7 +18,11 @@
|
||||
# I førstnevnte tilfelle må du også registrere boksen i './ssh_config_backup_targets'.
|
||||
|
||||
|
||||
echo "PVV; hjemmelaget backupscript (\$ git commit sha: $(cd /backupz && git rev-parse HEAD) \$)"
|
||||
if ! command -v git >/dev/null 2>&1; then
|
||||
echo "PVV; hjemmelaget backupscript (\$ git commit sha: ??? \$)"
|
||||
else
|
||||
echo "PVV; hjemmelaget backupscript (\$ git commit sha: $(cd /backupz && git rev-parse HEAD) \$)"
|
||||
fi
|
||||
echo
|
||||
date
|
||||
|
||||
|
||||
Reference in New Issue
Block a user