diff options
author | Thien-Thi Nguyen <ttn@gnuvola.org> | 2022-06-30 03:34:54 -0400 |
---|---|---|
committer | Thien-Thi Nguyen <ttn@gnuvola.org> | 2022-06-30 03:34:54 -0400 |
commit | 4cf70435b27fbe16a539e4d39ae0c745941f4d1c (patch) | |
tree | 3628249a6b25093ce772422f1efada04d97d4ce3 /contrib/gana-update.sh | |
parent | f3770761748b454222b1a0d8c3a94ec8b5ecae63 (diff) | |
download | exchange-4cf70435b27fbe16a539e4d39ae0c745941f4d1c.tar.xz |
fix portability bug: make sure destination file is writeable
Some shells let this go w/o comment, some don't.
Better to be sure.
(ensure): If "$dst" exists, make sure it is writeable.
Diffstat (limited to 'contrib/gana-update.sh')
-rwxr-xr-x | contrib/gana-update.sh | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/contrib/gana-update.sh b/contrib/gana-update.sh index e16c67413..b20bbaa1d 100755 --- a/contrib/gana-update.sh +++ b/contrib/gana-update.sh @@ -22,6 +22,7 @@ ensure () if ! diff $src $dst > /dev/null then + test ! -f $dst || chmod +w $dst cp $src $dst chmod -w $dst fi |