News for hackers. Stuff that matters.
Re:The Command Line Murders by mnw21cam on Friday January 29, 2016 @08:25AM (#10995021)
Wow. Lots of detail.

Zip? Seriously?

Re:The Command Line Murders by teebot on Friday January 29, 2016 @08:28AM (#10995033)
If it's a mystery to solve it makes sense not too include too many details :) You should just clone the repo. The zip option is always present on github repos.
Re:The Command Line Murders by laumars on Friday January 29, 2016 @10:27AM (#10995691)
If it bothers you that much then use git instead:

    git clone https://github.com/Kinto/kinto.git
But what you're complaining about has been an option on Github for years.
Re:The Command Line Murders by stryk on Friday January 29, 2016 @08:28AM (#10995036)
What's wrong with zip?
Re:The Command Line Murders by mnw21cam on Friday January 29, 2016 @08:37AM (#10995064)
Absolutely nothing. Just a little discordant to see grep et al being discussed in a project packaged as a zip. I suppose people might want to play with this in Windows, although to be honest if you have gone to the trouble to install grep et al, you will have no trouble with tar either.
Re:The Command Line Murders by noxToken on Friday January 29, 2016 @09:38AM (#10995390)
You're still missing the point. GitHub repos can be downloaded as a zip, because the zip file extension is easily compatible on all major operating systems.
Re:The Command Line Murders by irishcoffee on Friday January 29, 2016 @09:25AM (#10995305)
I'm not usually one to post these, but I can't help it in this care:

https://xkcd.com/1168/

Re:The Command Line Murders by teekert on Friday January 29, 2016 @09:43AM (#10995426)
tar zxvf! For tar.gz. Never, ever understood why the tar command can't just read the extension and determine the required long list of options needed for successful extraction. Whether I can remember tar xvjpf (for tar.bz2 files) depends on many things, not sure which. To be honest, I like it when I hit a .zip, I can just type "unzip x"...

Nice xkcd :)

Re:The Command Line Murders by pdkl95 on Friday January 29, 2016 @10:16AM (#10995631)
All I ever need to remember:

    atool -x archive.{zip,jar,rar,cab,deb,rpm,tar,tar.{gz,Z,bz2,xz}}
(list of supported formats is not complete)

With a simple alias, it isn't even necessary to remember the -x

    alias xx="atool -x"
This also protects you from badly made archives that explode hundreds of files into the current directory. All decompression is done in a temporary subdir, which is removed if there was only one file/dir at the top level.

For xkcd, see atool's --explain or --simulate options that show you the generated tar/etc commands.

http://www.nongnu.org/atool/

Re:The Command Line Murders by rcthompson on Friday January 29, 2016 @03:18PM (#10998161)
Atool already comes with appropriate aliases for all the common tasks:

    $ wajig list-files atool | grep bin/
    /usr/bin/atool
    /usr/bin/arepack
    /usr/bin/aunpack
    /usr/bin/apack
    /usr/bin/als
    /usr/bin/acat
    /usr/bin/adiff
Re:The Command Line Murders by Ianvdl on Friday January 29, 2016 @09:50AM (#10995476)
Newer versions of tar do automatically use the correct procedure based on the extension, just type tar xvf.
Re:The Command Line Murders by teekert on Friday January 29, 2016 @10:16AM (#10995628)
Woah, I was stuck in the past! Thanx for the tips!
Re:The Command Line Murders by delluminatus on Friday January 29, 2016 @09:58AM (#10995528)
Just do "tar -xf" for all your file extracting needs. The other command-line parameters are pretty much only needed if you want to override the detected compression format.
Re:The Command Line Murders by andrewaylett on Friday January 29, 2016 @09:55AM (#10995507)
It can.

    $ ls
    foo.tar.gz
    $ tar -xf foo.tar.gz
    $ ls
    foo.tar.gz
    my_file.md
Re:The Command Line Murders by takeda on Friday January 29, 2016 @03:21PM (#10998183)
It does, I always extract files with:

tar xf <file>

(as in eXtract File)

The xkcd answer could be: tar t

I always see people using tar -zxvf <file>, I'm guessing they tried that and it worked, and they never needed to look in the manpage. I feel that

Re:The Command Line Murders by yogiHacks on Friday January 29, 2016 @03:40PM (#10998325)
lame@user:~/$ tar --help
Re:The Command Line Murders by lazyant on Friday January 29, 2016 @09:53AM (#10995492)
Re:The Command Line Murders by gnaritas on Friday January 29, 2016 @10:58AM (#10995903)
Zip doesn't mean windows, lots of us Linux people don't like tar.
Re:The Command Line Murders by FullyFunctional on Friday January 29, 2016 @03:16PM (#10998151)
Lots of us Linux people don't like Zip, so?

To point out the obvious, Zip compresses files individually and then bundles them. A .tar.{Z,gz,bz2,xz,...} files bundles the files and then compresses them. The latter is better for entropy reduction, the former is better for random access. It all depends on your objectives.

Re:The Command Line Murders by gnaritas on Friday January 29, 2016 @08:38PM (#11000064)
Of course, but that's entirely beside the point; my comment was on the author assuming zip implied a windows user, it does not. Zip is ubiquitous on all OS's which is why github offers zip.
Re:The Command Line Murders by CamperBob2 on Saturday January 30, 2016 @12:50AM (#11000721)
What always leaves a puzzled look on my face (as a Windows user) is .tar.gz. What does .tar do in the case where there's nothing but a single gzipped file being archived?
Re:The Command Line Murders by FullyFunctional on Thursday February 04, 2016 @10:35PM (#11039233)
Preserves the permission, user, group, time-stamps, and complete original name and path. Granted, there's a small overlap with what gzip also provides, but a tar file is as close to the original as you generally gets. Oh, and exotic: support for sparse files (if enabled).
Re:The Command Line Murders by shabble on Friday January 29, 2016 @10:12AM (#10995609)
Re:The Command Line Murders by the8472 on Friday January 29, 2016 @01:00PM (#10997027)
would have been a great opportunity for gunzip.