aboutsummaryrefslogtreecommitdiff
path: root/g.sh
diff options
context:
space:
mode:
authorMiquel Sabaté <msabate@suse.com>2015-08-24 13:56:04 +0200
committerMiquel Sabaté <msabate@suse.com>2015-08-24 13:56:04 +0200
commitdeefef53041e15eb3e0c42dc9374179735f760fd (patch)
treed58ce5ac8658a6f658a6f1d7b480739950a4e4de /g.sh
parent974a3655ee95fd22f98262603dca4faf8ed0711f (diff)
downloadg-deefef53041e15eb3e0c42dc9374179735f760fd.tar.gz
g-deefef53041e15eb3e0c42dc9374179735f760fd.zip
Erase the contents of the g file in a portable way
Diffstat (limited to 'g.sh')
-rw-r--r--g.sh2
1 files changed, 1 insertions, 1 deletions
diff --git a/g.sh b/g.sh
index 3b9846d..b3cc3cc 100644
--- a/g.sh
+++ b/g.sh
@@ -53,7 +53,7 @@ __g_get_shortcuts() {
# Save the computed shortcuts into the __g_file.
__g_save_shortcuts() {
# Erase the contents of the __g_file.
- >$__g_file
+ :>$__g_file
# Finally write the hash into the __g_file.
for i in "${!__g_shortcuts[@]}"; do