Hello community,
here is the log from the commit of package obs-service-download_files for
openSUSE:Factory checked in at 2013-06-24 09:35:22
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/obs-service-download_files (Old)
and /work/SRC/openSUSE:Factory/.obs-service-download_files.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "obs-service-download_files"
Changes:
--------
---
/work/SRC/openSUSE:Factory/obs-service-download_files/obs-service-download_files.changes
2012-11-20 13:09:55.000000000 +0100
+++
/work/SRC/openSUSE:Factory/.obs-service-download_files.new/obs-service-download_files.changes
2013-06-24 09:35:22.000000000 +0200
@@ -1,0 +2,18 @@
+Fri Jun 21 20:04:15 UTC 2013 - [email protected]
+
+- move the setting of the wget command inside the loop to start
+ new on every iteration. Prevents interference of a specified
+ http user agent or output file name with the next loop iteration,
+ as it happens when several sources are present in the spec file.
+
+-------------------------------------------------------------------
+Wed Jun 19 21:22:56 UTC 2013 - [email protected]
+
+- Determine intended filename from URL fragment
+ * allows downloading from URLs not containing a filename, e.g.:
+ http://example.com/dl.cgi?{version}#/%{name}-%{version}.tar.gz
+ * allows downloading from URLS where the file name sent differs
+ from the one used in the package, e.g:
+ http://example.com/gpgkeys.asc#/%{name}.keyring
+
+-------------------------------------------------------------------
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ obs-service-download_files.spec ++++++
--- /var/tmp/diff_new_pack.4kUsKj/_old 2013-06-24 09:35:23.000000000 +0200
+++ /var/tmp/diff_new_pack.4kUsKj/_new 2013-06-24 09:35:23.000000000 +0200
@@ -1,7 +1,7 @@
#
# spec file for package obs-service-download_files
#
-# Copyright (c) 2012 SUSE LINUX Products GmbH, Nuernberg, Germany.
+# Copyright (c) 2013 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
++++++ download_files ++++++
--- /var/tmp/diff_new_pack.4kUsKj/_old 2013-06-24 09:35:23.000000000 +0200
+++ /var/tmp/diff_new_pack.4kUsKj/_new 2013-06-24 09:35:23.000000000 +0200
@@ -76,13 +76,13 @@
echo $BASENAME
}
-WGET="/usr/bin/wget -4 --no-check-certificate -q --timeout=30 --tries=2
--no-directories"
RETURN=0
for i in *.spec PKGBUILD; do
test -e "$i" || continue
for url in `perl -I/usr/lib/build -MBuild -e Build::show
/usr/lib/build/configs/default.conf "$i" sources`; do
+ WGET="/usr/bin/wget -4 --no-check-certificate --timeout=30 -q --tries=2
--no-directories"
MYCACHEDIRECTORY="$CACHEDIRECTORY"
PROTOCOL="${url%%:*}"
SAMEFILEAFTERCOMPRESSION=
@@ -98,6 +98,16 @@
# WGET="$WGET -O $BN"
# urlextension="/download"
else
+ # determine intended filename from URL fragment, e.g.
+ # https://www.example.com/gpgkeys.asc#/%{name}.keyring
+ FRAGMENT=`echo $url | perl -MURI -le 'chomp($url = <>); print
URI->new($url)->fragment'`
+ BN=`basename "$url"`
+ # fragment must begin with "/" and only contain a base name
+ if [ /"$BN" == "$FRAGMENT" ]; then
+ WGET="$WGET -O $BN"
+ fi
+ #
+
# We tell the server that we are an OBS tool by default
WGET="$WGET -U 'OBS-wget'"
urlextension=""
--
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]