diff options
author | Brendan Taylor <whateley@gmail.com> | 2010-11-21 23:12:48 -0700 |
---|---|---|
committer | Brendan Taylor <whateley@gmail.com> | 2010-11-21 23:12:48 -0700 |
commit | bb1153c9bc776d0c0dde44bcc055d40c7617a998 (patch) | |
tree | bc81643049c46e619c12d7b082a128d0a65da8a8 | |
parent | 400b23552e7a4e8f1219c677dc491f35e22d335a (diff) |
write new history and bookmark files if they don't already exist
-rwxr-xr-x | examples/data/scripts/history.sh | 2 | ||||
-rwxr-xr-x | examples/data/scripts/insert_bookmark.sh | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/examples/data/scripts/history.sh b/examples/data/scripts/history.sh index b91d415..0cd2218 100755 --- a/examples/data/scripts/history.sh +++ b/examples/data/scripts/history.sh @@ -2,6 +2,6 @@ source $UZBL_UTIL_DIR/uzbl-dir.sh -[ -w "$UZBL_HISTORY_FILE" ] || exit 1 +[ -w "$UZBL_HISTORY_FILE" ] || [ ! -a "$UZBL_HISTORY_FILE" ] || exit 1 echo $(date +'%Y-%m-%d %H:%M:%S')" $6 $7" >> $UZBL_HISTORY_FILE diff --git a/examples/data/scripts/insert_bookmark.sh b/examples/data/scripts/insert_bookmark.sh index 18f643f..08d7d2b 100755 --- a/examples/data/scripts/insert_bookmark.sh +++ b/examples/data/scripts/insert_bookmark.sh @@ -3,7 +3,7 @@ source $UZBL_UTIL_DIR/uzbl-dir.sh [ -d "$UZBL_DATA_DIR" ] || exit 1 -[ -w "$UZBL_BOOKMARKS_FILE" ] || exit 1 +[ -w "$UZBL_BOOKMARKS_FILE" ] || [ ! -a "$UZBL_BOOKMARKS_FILE" ] || exit 1 which zenity &>/dev/null || exit 2 # replace tabs, they are pointless in titles and we want to use tabs as delimiter. |