Mailinglist Archive: opensuse-buildservice (256 mails)

< Previous Next >
Re: [opensuse-buildservice] obs-service-download_files and Sourceforge
On 29 August 2011 07:51, Adrian Schröter <adrian@xxxxxxx> wrote:
Am Sonntag, 28. August 2011, 13:15:22 schrieb Cristian Morales Vega:
I used this kind of source tags with SourceForge:

Source0:
http://downloads.sourceforge.net/project/nsnam/ns-2/%{version}/ns-%{version}
.tar.gz


And the

    # Some web sites need a special user agent
    if echo $url | egrep -q '^http://[^/]*sourceforge.net/'; then
      # default wget user agent required, but /download suffix must be added
urlextension="/download"
    else

part of the download_files service is breaking it for me.
What's the logic behind appending "/download"?

That is interessting, it stopped to work without it for me since some time and
for example

 wget http://sourceforge.net/projects/nsnam/files/allinone/ns-
allinone-2.34/ns-allinone-2.34.tar.gz/download

works here. What is different at you side ?

I see. If I'm in

http://sourceforge.net/projects/nsnam/files/ns-2/2.34/

I can get this link:

http://sourceforge.net/projects/nsnam/files/ns-2/2.34/ns-2.34.tar.gz/download

And if I use it directly with wget it works. If I remove the
"/download" and try again what I get is a redirect to the same URL
with the "/download" appended.
The thing is I never tried with those links, I always clicked on them. And from

http://sourceforge.net/projects/nsnam/files/ns-2/2.34/ns-2.34.tar.gz/download

in your browser you get a web page with a "direct link" link to something as

http://downloads.sourceforge.net/project/nsnam/ns-2/2.34/ns-2.34.tar.gz?r=http%3A%2F%2Fsourceforge.net%2Fprojects%2Fnsnam%2Ffiles%2Fns-2%2F2.34%2F&ts=1314607211&use_mirror=freefr

What I always used is that, removing everything after the '?', so:

http://downloads.sourceforge.net/project/nsnam/ns-2/2.34/ns-2.34.tar.gz

And this doesn't works if you append the "/download".

In summary:

- Works
http://sourceforge.net/projects/nsnam/files/ns-2/2.34/ns-2.34.tar.gz/download
http://downloads.sourceforge.net/project/nsnam/ns-2/2.34/ns-2.34.tar.gz

- Works through a redirect
http://sourceforge.net/projects/nsnam/files/ns-2/2.34/ns-2.34.tar.gz

- Doesn't work
http://downloads.sourceforge.net/project/nsnam/ns-2/2.34/ns-2.34.tar.gz/download
--
To unsubscribe, e-mail: opensuse-buildservice+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: opensuse-buildservice+help@xxxxxxxxxxxx

< Previous Next >
Follow Ups