em wrote 3 years ago reply Hi! I try to achieve a quick and dirty txz2lzm script!
#Quick and dirty txz2lzm script
#Decompress .txz to .tar:
for f in *.txz; do xz -d $f; done
#Untar .tar to directories:
for f in *.tar; do d=`basename $f .tar`; mkdir $d; (cd $d && tar xf ../$f); done
#Delete .tar sources:
for f in *.tar; do rm -rfv $f; done
#Recompress directories to .lzm:
but finally, how to dir2lzm resulting directories to their respective .lzm files, and delete them?
If someone could help me!
Thanx in advance! burninbush wrote 3 years ago reply I have no clue what you are doing, or what a xxx.txz file might be ...
But dir2lzm on the top level directory of your temp directory structure will include everything that appears below it.
If that helps? em wrote 3 years ago reply burninbush thanx to you my friend! But that's not help me! Lol! But you try to help me and i wish to thanx for that and your previous help on the forum!
txz is the new slackware replacement tgz package format! A tar file compressed with the new XZ Utils compressor (lzma2) from The Tukaani Project!
downloadable from here:
Im looking for a bash script that can convert directly the Slackware .txz packages to Slax .lzm.
Some kind of replacement for tgz2lzm. It didnt exist yet! So i try to make one by myself!
Im near the final result!
But i didnt know how to convert multiple directory in multiple lzm at once by script!
If someone have a solution before i discover one ...
Thanx again for your time!
Regards! ShaneCoyle wrote 3 years ago reply I think you need to grab the latest pkgtools and xz tgz's from the slackware ftp, but then after that, you can continue to use the tgz2lzm script on txz's just as you always have on tgz's.
So, grab the pkgtools and xz packages here:
either installpkg them if you save changes, or tgz2lzm them and save them in your modules directory and either activate or reboot.
From then on, tgz2lzm foo.txz foo.lzm will work just fine, I believe. fanthom wrote 3 years ago reply Hi em!
I wrote rest of Your script:
for f in *
if [ "-d" "$f" ]; then
dir2lzm $f $f.lzm > /dev/null 2>&1
rm -r $f
echo "$f is not a directory - skipping"
echo "all jobs done"
tested and works fine, enjoy! em wrote 3 years ago reply Thanx to both of you for your collaborative efforts to help me to make this script running!
This script run like a charm now! But take care it remove all of the directories at the end!
So run it in a temp directory with your .txz files inside!
Now we can convert many .txz to .lzm in one right clic! Like in tgz2lzm before!
I gonna make a konqueror service menu now for right clic!
Thanx again to all of you, burnin (youre help on the forum), Shane (youre good suggestion), fanthom (youre excellent script!).
I try to fix some things before publishing a KDE3/4 servicemenu to slax modules when it done!
Many thanx again, long live to Slax, Tomas and all contributors!
Have fun! forum wrote 3 years ago reply Em, you don't need this. If you're going to use txz packages, you will also need all base packages updated, and that means pkgtools, too. That gives txz support to tgz2lzm.
Sorry, but it's pointless. Nobody's going to use txz packages in Slackware 12.2-based distribution, it's just stupid (it may cause errors). beny wrote 3 years ago reply the new slackware package are txz if you wont convert they,you need a script like em script, tgz is old format if you have kde 4 the package are only txz. em wrote 3 years ago reply Its only an helping tool for me to batch process txz and learning bash scrit to, lol!
But take note thats txz it's the future of Slackware 13.0 & KDE 4 to, even if i always use old good tgz.
So, like beny said, its time to keep an eye to the future package managing!
Be cool, aware and have fun with Slax! Like ever ... forum wrote 3 years ago reply If you want to keep an eye, just install the new pkgtools (they come in tgz) and explore them.
beny, I know, but KDE 4 packages may not work on Slax one way or another because they are compiled with newer dependency packages. ardu wrote 1 year ago reply A simple .txz to .tgz converter, save the following script as txz2tgz.sh:
for i in "$@"; do
o="$(basename $i .txz)".tgz
xz -dc "$i" | gzip -c > "$o"