diff options
author | EuAndreh <eu@euandre.org> | 2018-07-25 11:37:51 -0300 |
---|---|---|
committer | EuAndreh <eu@euandre.org> | 2018-07-25 11:40:26 -0300 |
commit | af18a634f88de063f3683c876e04fb95ae6ecda7 (patch) | |
tree | d3a949e99a409fa226027c1495b806a3eebaf4e5 /bash/util.sh | |
parent | Add missing clj services (diff) | |
download | dotfiles-af18a634f88de063f3683c876e04fb95ae6ecda7.tar.gz dotfiles-af18a634f88de063f3683c876e04fb95ae6ecda7.tar.xz |
Indent bash code with 2 spaces instead of 4
Diffstat (limited to 'bash/util.sh')
-rw-r--r-- | bash/util.sh | 38 |
1 files changed, 19 insertions, 19 deletions
diff --git a/bash/util.sh b/bash/util.sh index dfdfc12..cdf4fd5 100644 --- a/bash/util.sh +++ b/bash/util.sh @@ -1,25 +1,25 @@ #!/usr/bin/env bash extract () { - if [ -f $1 ] ; then - case $1 in - *.tar.bz2) tar xvjf $1 ;; - *.tar.gz) tar xvzf $1 ;; - *.bz2) bunzip2 $1 ;; - *.rar) unrar x $1 ;; - *.gz) gunzip $1 ;; - *.tar) tar xvf $1 ;; - *.tbz2) tar xvjf $1 ;; - *.tgz) tar xvzf $1 ;; - *.zip) unzip $1 ;; - *.Z) uncompress $1 ;; - *.7z) 7z x $1 ;; - *.xz) unxz $1 ;; - *) echo "don't know how to extract '$1'..." ;; - esac - else - echo "'$1' is not a valid file!" - fi + if [ -f $1 ] ; then + case $1 in + *.tar.bz2) tar xvjf $1 ;; + *.tar.gz) tar xvzf $1 ;; + *.bz2) bunzip2 $1 ;; + *.rar) unrar x $1 ;; + *.gz) gunzip $1 ;; + *.tar) tar xvf $1 ;; + *.tbz2) tar xvjf $1 ;; + *.tgz) tar xvzf $1 ;; + *.zip) unzip $1 ;; + *.Z) uncompress $1 ;; + *.7z) 7z x $1 ;; + *.xz) unxz $1 ;; + *) echo "don't know how to extract '$1'..." ;; + esac + else + echo "'$1' is not a valid file!" + fi } merkle-tree () { |