Welcome to the Linux Foundation Forum!

tar.gz or tar.bz2 with task bar

How do I get a task bar for the commmand line for the tar.gz or tar.bz2 when compressing files? I want a task like wget has for download and like you get when you tar.gz or tar.bz2 with a gui.

Comments

  • woboyle
    woboyle Posts: 501
    As far as I know, no such thing. FWIW, bzip2 compresses better, but is slower.

    Anyway, you can use the -vvvv option to bzip2 for progress details. Also the -v (or --verbose) option to gzip will display name and percentage of reduction for each file compressed, though this is not a "progress bar".
  • http://sourceforge.net/projects/clpbar/

    I fond the above program call bar it shows a prograss bar how ever I cant seem to get it to work for the command
    tar -zcf /home/dir/dir.tar.gz /home/dir/
    copy /home/dir /otherdir/dir

    I have attached the man bar so that you can help me. I tryed to read the man bar but could not make heads or tails of it. the man bar file is 34.4 kb so i had to zip it so that i could upload it. [file name=manbar.zip size=8739]http://www.linux.com/media/kunena/attachments/legacy/files/manbar.zip[/file] [file name=manbar.zip size=8739]http://www.linux.com/media/kunena/attachments/legacy/files/manbar.zip[/file]
  • best I have been able to do is this
    tar -zcvvvvf chant.tar.gz chant/ | zenity --progress --text="zipping" --percentage=1 --auto-kill

    have no idea as to how to get "--test=zipping" to show a % as the progress bar moves
  • tar -zcvvvvf file.tar.gz chant/ | tee | bar
  • tar -zcvvvvf file.tar.gz chant/ | tee | bar -s 328m

    get bar now but no move of bar stays at 0% however the # still run at bottom. any one know what I'm doing wrong?
  • mfillpot
    mfillpot Posts: 2,177
    I have tried the same and given up on using bar for that function because it is intended to read file transfer not compression. On somewhat simple solution would be to write a shell script that tracks the quantity of files and directories to be added to the archive and have it utilize and incrementing counter to display a progress bar displaying the amount of files that have been appended, however it would not be able to estimate time due to the unknown compression rates and times for each file.

Categories

Upcoming Training