pk rar added
This commit is contained in:
parent
08ee087646
commit
580f48a9de
|
@ -21,9 +21,9 @@ extract () {
|
||||||
|| bunzip2 -c $1 > ${1%.bz2} ;;
|
|| bunzip2 -c $1 > ${1%.bz2} ;;
|
||||||
*.gz) gunzip -c $1 > ${1%.gz} ;;
|
*.gz) gunzip -c $1 > ${1%.gz} ;;
|
||||||
*.xz) unxz -c $1 > ${1%.xz} ;;
|
*.xz) unxz -c $1 > ${1%.xz} ;;
|
||||||
*.rar) unrar x $1 ;; # FIXME: test
|
*.rar) unrar x $1 ;;
|
||||||
*.zip) unzip $1 ;;
|
*.zip) unzip $1 ;;
|
||||||
*.Z) uncompress $1 ;; # FIXME: test
|
#*.Z) uncompress $1 ;; # FIXME: test
|
||||||
*.7z) 7z x $1 ;;
|
*.7z) 7z x $1 ;;
|
||||||
*) echo "I don't know how to extract '$1'..." ;;
|
*) echo "I don't know how to extract '$1'..." ;;
|
||||||
esac
|
esac
|
||||||
|
@ -48,9 +48,9 @@ pk () {
|
||||||
|| bzip2 -9 -c $2 > $2.bz2 ;;
|
|| bzip2 -9 -c $2 > $2.bz2 ;;
|
||||||
g*z) gzip -c -9 -n $2 > $2.gz ;;
|
g*z) gzip -c -9 -n $2 > $2.gz ;;
|
||||||
x*z) xz -c -9 $2 > $2.xz ;;
|
x*z) xz -c -9 $2 > $2.xz ;;
|
||||||
rar) ;; # FIXME: test
|
rar) rar a $2.rar $2 -m5 ;;
|
||||||
zip) zip -9 -r $2.zip $2 ;;
|
zip) zip -9 -r $2.zip $2 ;;
|
||||||
Z) ;; # FIXME: test
|
#Z) ;; # FIXME: test
|
||||||
7z) 7z -mx=9 a $2.7z $2 ;;
|
7z) 7z -mx=9 a $2.7z $2 ;;
|
||||||
*) echo "'$1' cannot be packed via pk()" ;;
|
*) echo "'$1' cannot be packed via pk()" ;;
|
||||||
esac
|
esac
|
||||||
|
|
Loading…
Reference in New Issue