3 ms·
It's kind of a gray area, but looking closely I find it leans heavily towards the buggy, "unexpected behavior" side of things. Here's why: when encountering HT
by pierrec 10y ago
It's kind of a gray area, but looking closely I find it leans heavily towards the buggy, "unexpected behavior" side of things.
Here's why: when encountering HTTP->HTTP redirects, wget already ignores the redirected file name and writes to the original file name that was provided in the URL. It was strangely inconsistent that it specifically didn't do this for HTTP->FTP redirects, and at the very least the behavior should be consistent by default. This is clarified in the linked release notes, and also explains why they had no hesitation in considering it a wget bug and fixing it immediately.
As for the question of whether using redirected file names is more expected and intuitive, IMO providing a URL without specifying an output filename is basically a shorthand that merges the two arguments into one.