summaryrefslogtreecommitdiff
path: root/functions/utilities.zsh
diff options
context:
space:
mode:
authorChristo Kotze <onaforeignshore@hotmail.co.uk>2018-02-20 00:14:06 +0300
committerChristo Kotze <onaforeignshore@hotmail.co.uk>2018-02-20 00:14:06 +0300
commitd31ac26caa359c867f2f82d6fbfee2bb72cf22cc (patch)
treefac0d6d31a08aa3601f451f2607db3c781f7af23 /functions/utilities.zsh
parentf10a7daab02af4b23e161627bba3850823f3b678 (diff)
Another Travis test
Diffstat (limited to 'functions/utilities.zsh')
-rw-r--r--functions/utilities.zsh3
1 files changed, 2 insertions, 1 deletions
diff --git a/functions/utilities.zsh b/functions/utilities.zsh
index 5babee2f..fb1cc276 100644
--- a/functions/utilities.zsh
+++ b/functions/utilities.zsh
@@ -234,7 +234,8 @@ function truncatePath() {
# if the path is in the home folder, add "~/" to the start otherwise "/"
[[ $1 == "~"* ]] && trunc_path='~/' || trunc_path='/'
# split the path into an array using "/" as the delimiter
- local paths=(${(s:/:)${1//"~\/"/}})
+ local paths=$1
+ paths=(${(s:/:)${paths//"~\/"/}})
# declare locals for the directory being tested and its length
local test_dir test_dir_length
# do the needed truncation