summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAaron Ball <nullspoon@iohq.net>2016-10-07 19:05:21 -0600
committerAaron Ball <nullspoon@iohq.net>2016-10-07 19:05:21 -0600
commit24220697431101b3d070666a58a51c68bff783fa (patch)
tree0dea58daebf36527864fa38d7098ec700b9c485e
parent4f826dd335d96b2d04b1414b3ba53b09860c7ffc (diff)
parent6ceda7e3e675318dab36b067f516999625bbae57 (diff)
downloadandbackup-24220697431101b3d070666a58a51c68bff783fa.tar.gz
andbackup-24220697431101b3d070666a58a51c68bff783fa.tar.xz
Merge branch 'gzip'
-rwxr-xr-xandbackup.sh5
1 files changed, 2 insertions, 3 deletions
diff --git a/andbackup.sh b/andbackup.sh
index 2093832..9bb3326 100755
--- a/andbackup.sh
+++ b/andbackup.sh
@@ -67,8 +67,7 @@ function backup_app {
# Compress the backup
echo "Compressing userdata for ${app}"
cd ${backups}/${app}/
- tar -cf data.tar data
- bzip2 -f data.tar
+ tar -c data | gzip -c > data.tar.gz
rm -rf data
}
@@ -117,7 +116,7 @@ function restore_app {
# Decompress backup
echo "Decompressing user data for ${app}."
cd ${backups}/${app}/
- bunzip2 -c data.tar.bz2 | tar -x
+ gzip -d -c data.tar.gz | tar -x
# Copy the user data in
cp -rp ${backups}/${app}/data/* ${data}/

Generated by cgit