commit | 5b66401bd12e70550d145a834a4a225d4237ea96 | [log] [tgz] |
---|---|---|
author | Elliott Hughes <enh@google.com> | Wed May 01 16:05:29 2024 +0000 |
committer | Elliott Hughes <enh@google.com> | Wed May 01 16:05:29 2024 +0000 |
tree | fa2cc70b88fbaa0203f9d0ca8bbcb6a8a5e84ebc | |
parent | 7c075dd489f6d53217c2656b20ef619230baa367 [diff] |
Fix the post_update.sh annoyance that can remove a home directory. Test: ./post_update.sh Change-Id: I0796421b6903d1f7ce185418a141c61f9be9d4a2
diff --git a/post_update.sh b/post_update.sh index c07d65a..2b42dba 100755 --- a/post_update.sh +++ b/post_update.sh
@@ -1,8 +1,13 @@ #!/bin/bash +# external-updater provides: # $1 Path to the new version. # $2 Path to the old version. +if [ "$#" -lt 1 ]; then + echo 'need at least the path to the current version!' + exit 1 +fi cd $1 set -e