summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'untar.sh')
-rwxr-xr-xuntar.sh14
1 files changed, 14 insertions, 0 deletions
diff --git a/untar.sh b/untar.sh
new file mode 100755
index 0000000..2e5b77f
--- /dev/null
+++ b/untar.sh
@@ -0,0 +1,14 @@
1#!/bin/bash
2
3# Args
4# $1 - Base path
5# $2 - base directory of the untarred component
6# $3 - name of the component archive
7
8
9if [ -d $1/$2 ]; then
10 echo "Removing $1/$2"
11 rm -rf $1/$2
12fi
13
14tar -C $1 -zxf $3