Mike Gerwitz

Activist for User Freedom

aboutsummaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
authorMike Gerwitz <mike@mikegerwitz.com>2013-06-16 13:23:39 -0400
committerMike Gerwitz <mike@mikegerwitz.com>2013-06-16 13:23:39 -0400
commitc336800ca4288ce174f183de20cd1fdef2b37141 (patch)
tree6090251e0b3a2e3d61237fdb1accd37919cf297e /tools
parent3ec175ef0c5f27a924fdf90d7fd8c7bc8bd2002a (diff)
downloadthoughts-c336800ca4288ce174f183de20cd1fdef2b37141.tar.gz
thoughts-c336800ca4288ce174f183de20cd1fdef2b37141.tar.bz2
thoughts-c336800ca4288ce174f183de20cd1fdef2b37141.zip
:Corrected dest dir creation bug with doc-cp
The modification that created this bug was clearly not tested.
Diffstat (limited to 'tools')
-rwxr-xr-xtools/doc-cp3
1 files changed, 2 insertions, 1 deletions
diff --git a/tools/doc-cp b/tools/doc-cp
index bacf4f8..d0b6a05 100755
--- a/tools/doc-cp
+++ b/tools/doc-cp
@@ -30,7 +30,8 @@ sstrip()
}
# ensure that parent directory exists
-mkdir -p "${dest%/*}"
+dir="${2%/*}"
+[ -z "$dir" ] || mkdir -p "$dir"
dest="$( sstrip "$2" )"
cp -v "$1" "$dest"