-tc, --trimcharacter char cut filename after character, such as "_"
but it doesn't work for me, and I got a question mark (?) for separator
How are you passing this option? '?' is a shell meta-character, so you
should use something like
wget -tc '?'
to prevent expansion.
> could anyone give any tips? :)
The --content-disposition option could also help.
--
Home is the place where, when you have to go there, they have to take you in.
-- Robert Frost, "The Death of the Hired Man"
Eduardo M KALINOWSKI
edu...@kalinowski.com.br
--
To UNSUBSCRIBE, email to debian-us...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listm...@lists.debian.org
Base on your original statement of the problem (please try to keep the
relevant context in the messages as the discussion progress), something
like this might be an acceptable, though clunky, solution:
for URL in $(script); do wget -O $(echo "${URL#*://}" | tr / _) "$URL"; done
This bash-snippet loops of the URLs in the output of your script and
calls wget such that each page is saved under the name of the original,
non-redirected URL. Basic sanitizing of the output filenames is
performed by removing the scheme name from the beginning of the URLs and
replacing all slashes with underscores.
--
Regards, | http://users.icfo.es/Florian.Kulzer
Florian |
I’ve been using the soft at www.pathtoolong.com that resolves the long
http://www.pathtoolong.com filename & path issue and deletes locked files.
--
View this message in context: http://www.nabble.com/wget-file-name-is-too-long-tp23241664p23590988.html
Sent from the Debian User mailing list archive at Nabble.com.