From 7270a2c858fc54bbb9085fe20e51e84593752bc4 Mon Sep 17 00:00:00 2001 From: fszimnau Date: Mon, 14 Apr 2025 16:53:23 +0200 Subject: [PATCH] skripte vereinfacht mit etwas weniger fp verbrauch --- scripts/archive_and_compress.sh | 6 ++++-- scripts/decompress_and_unarchive.sh | 5 +++-- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/scripts/archive_and_compress.sh b/scripts/archive_and_compress.sh index 1386094..b4648d2 100755 --- a/scripts/archive_and_compress.sh +++ b/scripts/archive_and_compress.sh @@ -1,3 +1,5 @@ #!/usr/bin/env bash -source=${1%/}; # cut off trailing "/" -tar cfv $source.tar $source && xz $source.tar; +source=$1 +destinationPart=${1%/}; # cut off trailing "/" +# tar cfv $destinationPart.tar $source && xz $destinationPart.tar; +tar c -I"xz -v" -vf $destinationPart.tar.xz $source diff --git a/scripts/decompress_and_unarchive.sh b/scripts/decompress_and_unarchive.sh index b0f34c2..e2ed14c 100755 --- a/scripts/decompress_and_unarchive.sh +++ b/scripts/decompress_and_unarchive.sh @@ -1,4 +1,5 @@ #!/usr/bin/env bash source=$1; -archive=${source%.xz}; # cut off trailing ".xz" -unxz $source && tar xfv $archive +# archive=${source%.xz}; # cut off trailing ".xz" +# unxz $source && tar xfv $archive +tar x -I"unxz -v" -vf $source