aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
authorEgor Tensin <Egor.Tensin@gmail.com>2017-01-15 23:28:53 +0300
committerEgor Tensin <Egor.Tensin@gmail.com>2017-01-15 23:28:53 +0300
commit0fb4ee5b98e1d06ed1194c6264fd3c6e781d9384 (patch)
treed5bbdfc2636554907fe14a26ca4d2046c560deef
parentadd branch_eol_normalized (diff)
downloadlinux-home-0fb4ee5b98e1d06ed1194c6264fd3c6e781d9384.tar.gz
linux-home-0fb4ee5b98e1d06ed1194c6264fd3c6e781d9384.zip
bugfix
Diffstat (limited to '')
-rw-r--r--%HOME%/.bash_utils/file.sh6
-rw-r--r--%HOME%/.bash_utils/git.sh2
-rwxr-xr-xbackup_gitconfig.sh2
3 files changed, 5 insertions, 5 deletions
diff --git a/%HOME%/.bash_utils/file.sh b/%HOME%/.bash_utils/file.sh
index 6741067..33f9994 100644
--- a/%HOME%/.bash_utils/file.sh
+++ b/%HOME%/.bash_utils/file.sh
@@ -29,7 +29,7 @@ swap_files() (
local tmp_path
tmp_path="$( mktemp -- "$( dirname -- "$path1" )/XXX" )"
- mv "$path1" "$tmp_path"
- mv "$path2" "$path1"
- mv "$tmp_path" "$path2"
+ mv -- "$path1" "$tmp_path"
+ mv -- "$path2" "$path1"
+ mv -- "$tmp_path" "$path2"
)
diff --git a/%HOME%/.bash_utils/git.sh b/%HOME%/.bash_utils/git.sh
index 9204847..456f29e 100644
--- a/%HOME%/.bash_utils/git.sh
+++ b/%HOME%/.bash_utils/git.sh
@@ -120,7 +120,7 @@ backup_repo() (
fi
local zip_name
- zip_name="${repo_name}_$( date -u +'%Y%m%dT%H%M%S' ).zip"
+ zip_name="${repo_name}_$( date --utc -- '+%Y%m%dT%H%M%S' ).zip"
git archive \
--format=zip -9 \
diff --git a/backup_gitconfig.sh b/backup_gitconfig.sh
index 30d13ea..d0224a5 100755
--- a/backup_gitconfig.sh
+++ b/backup_gitconfig.sh
@@ -2,5 +2,5 @@
set -o errexit -o nounset -o pipefail
-script_dir="$( cd "$( dirname -- "${BASH_SOURCE[0]}" )" && pwd )"
+script_dir="$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" && pwd )"
cp --remove-destination -- "$script_dir/%HOME%/.gitconfig" ~