Debian Bug report logs - #685787
devscripts: Enabling uscan to simply remove files from upstream source

version graph

Package: devscripts; Maintainer for devscripts is Devscripts Devel Team <devscripts-devel@lists.alioth.debian.org>; Source for devscripts is src:devscripts.

Reported by: Andreas Tille <tille@debian.org>

Date: Fri, 24 Aug 2012 14:45:02 UTC

Severity: wishlist

Tags: patch

Merged with 677270

Found in versions devscripts/2.10.69+squeeze2, devscripts/2.10.69, devscripts/2.11.8

Fixed in version devscripts/2.13.5

Done: James McCoy <jamessan@debian.org>

Bug is archived. No further changes may be made.

Toggle useless messages

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to debian-bugs-dist@lists.debian.org, debian-devel@lists.debian.org, Devscripts Devel Team <devscripts-devel@lists.alioth.debian.org>:
Bug#685787; Package devscripts. (Fri, 24 Aug 2012 14:45:04 GMT) Full text and rfc822 format available.

Acknowledgement sent to Andreas Tille <tille@debian.org>:
New Bug report received and forwarded. Copy sent to debian-devel@lists.debian.org, Devscripts Devel Team <devscripts-devel@lists.alioth.debian.org>. (Fri, 24 Aug 2012 14:45:04 GMT) Full text and rfc822 format available.

Message #5 received at submit@bugs.debian.org (full text, mbox):

From: Andreas Tille <tille@debian.org>
To: Debian Bug Tracking System <submit@bugs.debian.org>
Subject: devscripts: Enabling uscan to simply remove files from upstream source
Date: Fri, 24 Aug 2012 16:38:13 +0200
[Message part 1 (text/plain, inline)]
Package: devscripts
Version: 2.10.69+squeeze2
Severity: wishlist
Tags: patch

Hi,

in a (bit longish) thread on debian-devel@l.d.o[1] there was some
discussion about enabling uscan to remove files from upstream archives
according to some information given in some control file.  There was no
real consensus about what control file to use.  The implementation below
is based on using debian/copyright but is easy to switch to other files
in case some other consensus might be reached.

The attached patch does the following:

 1. If (and only if) the debian/copyright file is

     Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/

    and if it contains a non-empty field Files-Excluded containing a
    space separated list of globs (as used by find and for specifying
    file lists in machine readable debian/control files). The deletion
    process will loop over every expression and is using the find
    command to delete the according globs.

 2. If files matching are contained in the source tarball this will
    be repackaged except if the option --no-exclusion is given at
    uscan command line or if USCAN_NO_EXCLUSION is set in
    /etc/devscripts.conf or ~/.devscripts.  The removal is implemented
    for all tar compression methods as well as for zip archives (which
    are unpackaged using unzip).  This means if the conditions for
    file exclusion as given above are fullfilled the patch below
    works similar as --repack.

 3. If the tarball did not contained any of the globs in
    debian/copyright::Files-Excluded it will be left untouched.

 4. In case something was removed the version string will be appended by
    '+dfsg' to express the fact that the content of the original source
    was changed.  Note: There was no real consensus whether to use this
    suffix or rather '~dfsg'.  This could be solved by some additional
    configuration option that could be added later.  For some moment I
    also had the idea to obtain the suffix which is "wanted" by the
    maintainer either from debian/watch:dversionmangle or
    debian/changelog but I droped this idea because I did not found
    a reliable method to make a safe guess.

 5. Sometimes upstream tarballs are dirty and unpack a load of files
    into the current directory.  The patch tries to behave reasonable
    and checks whether it could move those files into a dir named
      $pkg-$newversion
    (in case no such file or directory just exists in such a dirty
    tarball).  Also some non-dirty but quite generically named
    directories (like "source") are renamed to "$pkg-$newversion".

I have tested the code with five different packages in Debian Med
repository which show different problematic directory structures and
also different compression methods.  The according copyright files
including Files-Excluded are commited to the following locations:

  Vcs-Svn: svn://svn.debian.org/debian-med/trunk/packages/ampliconnoise/trunk/
  Vcs-Svn: svn://svn.debian.org/debian-med/trunk/packages/conquest-dicom-server/trunk/
  Vcs-Svn: svn://svn.debian.org/debian-med/trunk/packages/imagej/trunk/
  Vcs-Svn: svn://svn.debian.org/debian-med/trunk/packages/saint/trunk/
  Vcs-Svn: svn://svn.debian.org/debian-med/trunk/packages/tm-align/trunk/

When applying the patch and using `uscan --verbose --force-download`
I get the actual resulting orig.tar.gz as I want it to be.

Remark:
Regarding the implementation there was some uncertainity about the
actual Perl module to use.  In the patch below script I decided to
stick to Dpkg::Control and left the code for Parse::DebControl as a
comment which could pretty easily could replace the other parser.

Please consider applying this patch after possibly further discussion on
debian-devel@l.d.o.

Kind regards

      Andreas.

PS: Some more skilled Perl programmer might see some room for enhancing
    the code - just be warned that Perl is not my native language.

[1] http://lists.debian.org/debian-devel/2012/08/msg00380.html

-- Package-specific info:

--- /etc/devscripts.conf ---

--- ~/.devscripts ---
Not present

-- System Information:
Debian Release: 6.0.5
Architecture: i386 (i686)

Kernel: Linux 2.6.36-xenU-4814-i386 (SMP w/1 CPU core)
Locale: LANG=de_DE.UTF-8, LC_CTYPE=de_DE.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash

Versions of packages devscripts depends on:
ii  dpkg-dev               1.15.8.12         Debian package development tools
ii  libc6                  2.11.3-3          Embedded GNU C Library: Shared lib
ii  perl                   5.10.1-17squeeze3 Larry Wall's Practical Extraction 

Versions of packages devscripts recommends:
pn  at                 <none>                (no description available)
ii  bsd-mailx [mailx]  8.1.2-0.20100314cvs-1 simple mail user agent
ii  curl               7.21.0-2.1+squeeze2   Get a file from an HTTP, HTTPS or 
ii  dctrl-tools        2.14.5                Command-line tools to process Debi
pn  debian-keyring     <none>                (no description available)
pn  debian-maintainers <none>                (no description available)
ii  dput               0.9.6.1+squeeze1      Debian package upload tool
pn  equivs             <none>                (no description available)
ii  fakeroot           1.14.4-1              Gives a fake root environment
ii  git [git-core]     1:1.7.2.5-3           fast, scalable, distributed revisi
ii  git-core           1:1.7.2.5-3           fast, scalable, distributed revisi
ii  gnupg              1.4.10-4              GNU privacy guard - a free PGP rep
pn  libauthen-sasl-per <none>                (no description available)
pn  libcrypt-ssleay-pe <none>                (no description available)
pn  libjson-perl       <none>                (no description available)
pn  libparse-debcontro <none>                (no description available)
pn  libsoap-lite-perl  <none>                (no description available)
pn  libterm-size-perl  <none>                (no description available)
ii  libtimedate-perl   1.2000-1              collection of modules to manipulat
ii  liburi-perl        1.54-2                module to manipulate and access UR
ii  libwww-perl        5.836-1               Perl HTTP/WWW client/server librar
pn  libyaml-syck-perl  <none>                (no description available)
pn  lintian            <none>                (no description available)
ii  lsb-release        3.2-23.2squeeze1      Linux Standard Base version report
ii  lynx-cur [www-brow 2.8.8dev.5-1          Text-mode WWW Browser with NLS sup
ii  lzma               4.43-14               Compression method of 7z format in
ii  mailx              1:20071201-3          Transitional package for mailx ren
ii  man-db             2.5.7-8               on-line manual pager
ii  openssh-client [ss 1:5.5p1-6+squeeze2    secure shell (SSH) client, for sec
ii  patch              2.6-2                 Apply a diff file to an original
ii  patchutils         0.3.1-2               Utilities to work with patches
ii  sensible-utils     0.0.4                 Utilities for sensible alternative
pn  strace             <none>                (no description available)
ii  unzip              6.0-4                 De-archiver for .zip files
ii  w3m [www-browser]  0.5.2-9               WWW browsable pager with excellent
pn  wdiff              <none>                (no description available)
ii  wget               1.12-2.1              retrieves files from the web
ii  xz-utils           5.0.0-2               XZ-format compression utilities

Versions of packages devscripts suggests:
ii  build-essential        11.5              Informational list of build-essent
pn  cvs-buildpackage       <none>            (no description available)
pn  devscripts-el          <none>            (no description available)
pn  gnuplot                <none>            (no description available)
pn  libfile-desktopentry-p <none>            (no description available)
pn  libnet-smtp-ssl-perl   <none>            (no description available)
ii  mutt                   1.5.20-9+squeeze2 text-based mailreader supporting M
pn  svn-buildpackage       <none>            (no description available)
ii  w3m                    0.5.2-9           WWW browsable pager with excellent

-- no debconf information
[exclude-files.diff (text/x-diff, attachment)]

Information forwarded to debian-bugs-dist@lists.debian.org, Devscripts Devel Team <devscripts-devel@lists.alioth.debian.org>:
Bug#685787; Package devscripts. (Sat, 25 Aug 2012 03:12:03 GMT) Full text and rfc822 format available.

Acknowledgement sent to Charles Plessy <plessy@debian.org>:
Extra info received and forwarded to list. Copy sent to Devscripts Devel Team <devscripts-devel@lists.alioth.debian.org>. (Sat, 25 Aug 2012 03:12:03 GMT) Full text and rfc822 format available.

Message #10 received at 685787@bugs.debian.org (full text, mbox):

From: Charles Plessy <plessy@debian.org>
To: Andreas Tille <tille@debian.org>, 685787@bugs.debian.org
Subject: Re: Bug#685787: devscripts: Enabling uscan to simply remove files from upstream source
Date: Sat, 25 Aug 2012 12:08:54 +0900
Le Fri, Aug 24, 2012 at 04:38:13PM +0200, Andreas Tille a écrit :
> 
>  1. If (and only if) the debian/copyright file is
> 
>      Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/

Hi Andreas,

I think that this is too strict.  For instance, if the format specification is
updated to incorporate the Files-Excluded field, then its version number will
increase and then uscan will stop removing excluded files from the package
where the Format field has been updated accordingly.

Perhaps we should try to find a consensus on the version scheme, for instance
proposing that there will be no backwards-incompatible change without increasing
the major version number, or perhaps you can ignore the version number completely
for the moment ?

Have a nice day,

-- 
Charles Plessy
Tsurumi, Kanagawa, Japan



Information forwarded to debian-bugs-dist@lists.debian.org, Devscripts Devel Team <devscripts-devel@lists.alioth.debian.org>:
Bug#685787; Package devscripts. (Sat, 25 Aug 2012 05:33:04 GMT) Full text and rfc822 format available.

Acknowledgement sent to Andreas Tille <andreas@fam-tille.de>:
Extra info received and forwarded to list. Copy sent to Devscripts Devel Team <devscripts-devel@lists.alioth.debian.org>. (Sat, 25 Aug 2012 05:33:04 GMT) Full text and rfc822 format available.

Message #15 received at 685787@bugs.debian.org (full text, mbox):

From: Andreas Tille <andreas@fam-tille.de>
To: 685787@bugs.debian.org, Debian Developers <debian-devel@lists.debian.org>
Subject: Re: Bug#685787: devscripts: Enabling uscan to simply remove files from upstream source
Date: Sat, 25 Aug 2012 07:28:59 +0200
On Sat, Aug 25, 2012 at 12:08:54PM +0900, Charles Plessy wrote:
> Le Fri, Aug 24, 2012 at 04:38:13PM +0200, Andreas Tille a écrit :
> > 
> >  1. If (and only if) the debian/copyright file is
> > 
> >      Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/
> 
> I think that this is too strict.  For instance, if the format specification is
> updated to incorporate the Files-Excluded field, then its version number will
> increase and then uscan will stop removing excluded files from the package
> where the Format field has been updated accordingly.

You are right here.
 
> Perhaps we should try to find a consensus on the version scheme, for instance
> proposing that there will be no backwards-incompatible change without increasing
> the major version number, or perhaps you can ignore the version number completely
> for the moment ?

I guess you mean something like this:

$ git diff
diff --git a/scripts/uscan.pl b/scripts/uscan.pl
index e118142..270fc3e 100755
--- a/scripts/uscan.pl
+++ b/scripts/uscan.pl
@@ -1448,7 +1448,7 @@ EOF
         $data->load('debian/copyright');
         # my $parser = new Parse::DebControl(1);
         # my $data = $parser->parse_file('debian/copyright', {discardCase=>1,singleBlock=>1,});
-        my $okformat = qr'http://www.debian.org/doc/packaging-manuals/copyright-format/1.0';
+        my $okformat = qr'http://www.debian.org/doc/packaging-manuals/copyright-format/[.\d]+';
         if ($data->{'format'} =~ m{^$okformat/?$} and $data->{'files-excluded'} ) {
             my $tempdir = tempdir ( "uscanXXXX", TMPDIR => 1, CLEANUP => 1 );
             my $globpattern = "*";


That's perfectly fine for me - thanks for the hint.

Kind regards

        Andreas.

-- 
http://fam-tille.de



Information forwarded to debian-bugs-dist@lists.debian.org, Devscripts Devel Team <devscripts-devel@lists.alioth.debian.org>:
Bug#685787; Package devscripts. (Sat, 25 Aug 2012 13:03:05 GMT) Full text and rfc822 format available.

Acknowledgement sent to gregor herrmann <gregoa@debian.org>:
Extra info received and forwarded to list. Copy sent to Devscripts Devel Team <devscripts-devel@lists.alioth.debian.org>. (Sat, 25 Aug 2012 13:03:05 GMT) Full text and rfc822 format available.

Message #20 received at 685787@bugs.debian.org (full text, mbox):

From: gregor herrmann <gregoa@debian.org>
To: Andreas Tille <tille@debian.org>, 685787@bugs.debian.org
Subject: Re: Bug#685787: devscripts: Enabling uscan to simply remove files from upstream source
Date: Sat, 25 Aug 2012 14:59:33 +0200
[Message part 1 (text/plain, inline)]
On Fri, 24 Aug 2012 16:38:13 +0200, Andreas Tille wrote:

> in a (bit longish) thread on debian-devel@l.d.o[1] there was some
> discussion about enabling uscan to remove files from upstream archives
> according to some information given in some control file.  There was no
> real consensus about what control file to use.  The implementation below
> is based on using debian/copyright but is easy to switch to other files
> in case some other consensus might be reached.

Thanks!
 
> The attached patch does the following:

Attached are some patches based on devscipts+git plus your original
patch.

The important one is
0003-Rename-directory-in-renamed-tarball-to-pkg-newversio.patch which
renames the directory in the new tarball to 
 $pkg - $newversion $excludesuffix .orig
as recommended in DevRef 6.7.8.2.


Cheers,
gregor
 

-- 
 .''`.  Homepage: http://info.comodo.priv.at/ - OpenPGP key 0xBB3A68018649AA06
 : :' : Debian GNU/Linux user, admin, and developer  -  http://www.debian.org/
 `. `'  Member of VIBE!AT & SPI, fellow of the Free Software Foundation Europe
   `-   NP: Ry Cooder: Let's Work Together
[0001-whitespace.patch (text/x-diff, attachment)]
[0002-s-fuffix-suffix-g.patch (text/x-diff, attachment)]
[0003-Rename-directory-in-renamed-tarball-to-pkg-newversio.patch (text/x-diff, attachment)]
[0004-add-support-for-.jar.patch (text/x-diff, attachment)]
[0005-Output-messages-about-the-files-excluding-action.patch (text/x-diff, attachment)]
[signature.asc (application/pgp-signature, inline)]

Information forwarded to debian-bugs-dist@lists.debian.org, Devscripts Devel Team <devscripts-devel@lists.alioth.debian.org>:
Bug#685787; Package devscripts. (Sat, 25 Aug 2012 15:51:06 GMT) Full text and rfc822 format available.

Acknowledgement sent to Andreas Tille <tille@debian.org>:
Extra info received and forwarded to list. Copy sent to Devscripts Devel Team <devscripts-devel@lists.alioth.debian.org>. (Sat, 25 Aug 2012 15:51:06 GMT) Full text and rfc822 format available.

Message #25 received at 685787@bugs.debian.org (full text, mbox):

From: Andreas Tille <tille@debian.org>
To: 685787@bugs.debian.org
Cc: Debian Developers <debian-devel@lists.debian.org>
Subject: Re: Bug#685787: devscripts: Enabling uscan to simply remove files from upstream source
Date: Sat, 25 Aug 2012 17:47:19 +0200
On Sat, Aug 25, 2012 at 02:59:33PM +0200, gregor herrmann wrote:
> > The attached patch does the following:
> 
> Attached are some patches based on devscipts+git plus your original
> patch.

I forgot to mention that my patch was also based on devscripts git and I
wonder whether somebody from the devscripts team might consider it
reasonable if we directly commit to the Git repository instead of sending
patches to BTS.
 
> The important one is
> 0003-Rename-directory-in-renamed-tarball-to-pkg-newversio.patch which
> renames the directory in the new tarball to 
>  $pkg - $newversion $excludesuffix .orig
> as recommended in DevRef 6.7.8.2.

Thanks for the patches.  Without testing from pure reading all makes
perfect sense to me.

Thanks

      Andreas.

-- 
http://fam-tille.de



Information forwarded to debian-bugs-dist@lists.debian.org, Devscripts Devel Team <devscripts-devel@lists.alioth.debian.org>:
Bug#685787; Package devscripts. (Sun, 26 Aug 2012 13:33:08 GMT) Full text and rfc822 format available.

Acknowledgement sent to Andreas Tille <tille@debian.org>:
Extra info received and forwarded to list. Copy sent to Devscripts Devel Team <devscripts-devel@lists.alioth.debian.org>. (Sun, 26 Aug 2012 13:33:08 GMT) Full text and rfc822 format available.

Message #30 received at 685787@bugs.debian.org (full text, mbox):

From: Andreas Tille <tille@debian.org>
To: gregor herrmann <gregoa@debian.org>
Cc: 685787@bugs.debian.org
Subject: Re: Bug#685787: devscripts: Enabling uscan to simply remove files from upstream source
Date: Sun, 26 Aug 2012 15:30:44 +0200
[Message part 1 (text/plain, inline)]
Hi Gregor,

I reverted one single line in your patch because this would break one of
my test cases namely

   Vcs-Svn: svn://svn.debian.org/debian-med/trunk/packages/saint/trunk/

and does not fit my intention.  You tried to check whether upstream might
contain a dir /^$pkg\w*$newversion$excludesuffix\.orig$/ which is most
probably never the case (why should upstream name something ".orig"?).
The intention of my check was to verify whether upstream source contains
something like a reasonable directory containing

   /^$pkg\w*$newversion$/

and do not try to undirty the tarball if this is the case.  It is true
that in this specific case we fail to name the directory ".orig" ...
but that's IMHO something we could hardly control.

I attached another Git formated patch and repeat my question whether
it might make sense to directly commit to the devscripts repository.

Kind regards

       Andreas.

On Sat, Aug 25, 2012 at 02:59:33PM +0200, gregor herrmann wrote:
> On Fri, 24 Aug 2012 16:38:13 +0200, Andreas Tille wrote:
> 
> > in a (bit longish) thread on debian-devel@l.d.o[1] there was some
> > discussion about enabling uscan to remove files from upstream archives
> > according to some information given in some control file.  There was no
> > real consensus about what control file to use.  The implementation below
> > is based on using debian/copyright but is easy to switch to other files
> > in case some other consensus might be reached.
> 
> Thanks!
>  
> > The attached patch does the following:
> 
> Attached are some patches based on devscipts+git plus your original
> patch.
> 
> The important one is
> 0003-Rename-directory-in-renamed-tarball-to-pkg-newversio.patch which
> renames the directory in the new tarball to 
>  $pkg - $newversion $excludesuffix .orig
> as recommended in DevRef 6.7.8.2.
> 
> 
> Cheers,
> gregor
>  
> 
> -- 
>  .''`.  Homepage: http://info.comodo.priv.at/ - OpenPGP key 0xBB3A68018649AA06
>  : :' : Debian GNU/Linux user, admin, and developer  -  http://www.debian.org/
>  `. `'  Member of VIBE!AT & SPI, fellow of the Free Software Foundation Europe
>    `-   NP: Ry Cooder: Let's Work Together

> From 34d41b8480c3467304383df3633c03ce6c5f34e2 Mon Sep 17 00:00:00 2001
> From: gregor herrmann <gregoa@debian.org>
> Date: Sat, 25 Aug 2012 14:12:10 +0200
> Subject: [PATCH 1/5] whitespace
> 
> ---
>  scripts/uscan.pl |    4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/scripts/uscan.pl b/scripts/uscan.pl
> index e118142..1ea4489 100755
> --- a/scripts/uscan.pl
> +++ b/scripts/uscan.pl
> @@ -2099,7 +2099,7 @@ sub get_main_source_dir($$$) {
>      print "-- Dirty tarball found.\n" if $verbose;
>      if ( $main_source_dir ) { # if tarball is dirty but does contain a $pkg-$newversion dir we will not undirty but leave it as is
>          print "-- No idea how to create proper tarball structure - leaving as is.\n" if $verbose;
> -    	return $tempdir;
> +        return $tempdir;
>      }
>      print "-- Move files to subdirectory $pkg-$newversion.\n" if $verbose;
>      $main_source_dir = $tempdir . '/' . $pkg . '-' . $newversion ;
> @@ -2108,7 +2108,7 @@ sub get_main_source_dir($$$) {
>  	unless ($file =~ /^\.\.?/) {
>              # move("${tempdir}/$file", $main_source_dir) or die("Unable to move ${tempdir}/$file directory $main_source_dir\n");
>              unless ( move("${tempdir}/$file", $main_source_dir) ) {
> -        	# HELP: why can't perl move not move directories????
> +            # HELP: why can't perl move not move directories????
>                  print "Perl move seems to be not able to ` move(\"${tempdir}/$file\", $main_source_dir) ` ... trying system mv\n" if $debug;
>                  system( "mv ${tempdir}/$file $main_source_dir" ) ;
>              }
> -- 
> 1.7.10.4
> 

> From 67b13a72c801fb7419254784e443a90506819bc4 Mon Sep 17 00:00:00 2001
> From: gregor herrmann <gregoa@debian.org>
> Date: Sat, 25 Aug 2012 14:19:48 +0200
> Subject: [PATCH 2/5] s/fuffix/suffix/g
> 
> ---
>  scripts/uscan.pl |    4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/scripts/uscan.pl b/scripts/uscan.pl
> index 1ea4489..cd69217 100755
> --- a/scripts/uscan.pl
> +++ b/scripts/uscan.pl
> @@ -1483,9 +1483,9 @@ EOF
>              if ( $nfiles_before == $nfiles_after ) {
>                  print "-- Source tree remains identical - no need for repacking.\n" if $verbose;
>              } else {
> -                my $excludefuffix = '+dfsg' ;
> +                my $excludesuffix = '+dfsg' ;
>                  my $suffix = 'gz' ;
> -                my $newfile_base_dfsg = "${pkg}_${newversion}${excludefuffix}.orig.tar.$suffix" ;
> +                my $newfile_base_dfsg = "${pkg}_${newversion}${excludesuffix}.orig.tar.$suffix" ;
>                  system("cd $tempdir; GZIP='-n -9' tar --owner=root --group=root --mode=a+rX -czf \"$absdestdir/$newfile_base_dfsg\" $globpattern") == 0
>                     or die("Excluding files failed (could not create tarball)\n");
>                  $symlink = 'no' # prevent symlinking or renaming
> -- 
> 1.7.10.4
> 

> From d40d483fb870b1a8efea2b2c77a70cf3358f3fb5 Mon Sep 17 00:00:00 2001
> From: gregor herrmann <gregoa@debian.org>
> Date: Sat, 25 Aug 2012 14:29:50 +0200
> Subject: [PATCH 3/5] Rename directory in renamed tarball to $pkg -
>  $newversion $excludesuffix .orig
> MIME-Version: 1.0
> Content-Type: text/plain; charset=UTF-8
> Content-Transfer-Encoding: 8bit
> 
> DevRef § 6.7.8.2
> ---
>  scripts/uscan.pl |   16 ++++++++--------
>  1 file changed, 8 insertions(+), 8 deletions(-)
> 
> diff --git a/scripts/uscan.pl b/scripts/uscan.pl
> index cd69217..cb29f44 100755
> --- a/scripts/uscan.pl
> +++ b/scripts/uscan.pl
> @@ -75,7 +75,7 @@ sub dehs_die ($);
>  sub dehs_output ();
>  sub quoted_regex_replace ($);
>  sub safe_replace ($$);
> -sub get_main_source_dir($$$);
> +sub get_main_source_dir($$$$);
>  
>  sub usage {
>      print <<"EOF";
> @@ -1465,7 +1465,8 @@ EOF
>                  system('unzip', '-q', '-a', '-d', $tempdir, "$destdir/$newfile_base") == 0
>                     or die("Repacking from zip to tar.gz failed (could not unzip)\n");
>              }
> -            my $main_source_dir = get_main_source_dir($tempdir, $pkg, $newversion);
> +            my $excludesuffix = '+dfsg' ;
> +            my $main_source_dir = get_main_source_dir($tempdir, $pkg, $newversion, $excludesuffix);
>              unless ( -d $main_source_dir ) {
>                  print STDERR "Error: $main_source_dir is no directory";
>              }
> @@ -1483,7 +1484,6 @@ EOF
>              if ( $nfiles_before == $nfiles_after ) {
>                  print "-- Source tree remains identical - no need for repacking.\n" if $verbose;
>              } else {
> -                my $excludesuffix = '+dfsg' ;
>                  my $suffix = 'gz' ;
>                  my $newfile_base_dfsg = "${pkg}_${newversion}${excludesuffix}.orig.tar.$suffix" ;
>                  system("cd $tempdir; GZIP='-n -9' tar --owner=root --group=root --mode=a+rX -czf \"$absdestdir/$newfile_base_dfsg\" $globpattern") == 0
> @@ -2070,8 +2070,8 @@ sub safe_replace($$) {
>      }
>  }
>  
> -sub get_main_source_dir($$$) {
> -    my ($tempdir, $pkg, $newversion) = @_;
> +sub get_main_source_dir($$$$) {
> +    my ($tempdir, $pkg, $newversion, $excludesuffix) = @_;
>      my $fcount = 0;
>      my $main_source_dir = '' ;
>      my $any_dir = '' ;
> @@ -2083,7 +2083,7 @@ sub get_main_source_dir($$$) {
>              $fcount++;
>  	    if ( -d $tempdir.'/'.$file ) {
>                  $any_dir = $tempdir . '/' . $file ;
> -                $main_source_dir = $any_dir if ( $file =~ /^$pkg\w*$newversion$/i ) ;
> +                $main_source_dir = $any_dir if ( $file =~ /^$pkg\w*$newversion$excludesuffix\.orig$/i ) ;
>              }
>          }
>      }
> @@ -2092,7 +2092,7 @@ sub get_main_source_dir($$$) {
>      }
>      if ( $fcount == 1 and $any_dir ) {
>          # Unusual base dir in tarball - should be rather something like ${pkg}-${newversion}
> -        $main_source_dir = $tempdir . '/' . $pkg . '-' . $newversion ;
> +        $main_source_dir = $tempdir . '/' . $pkg . '-' . $newversion . $excludesuffix . '.orig';
>          move($any_dir, $main_source_dir) or die("Unable to move $any_dir directory $main_source_dir\n");
>          return $main_source_dir ;
>      }
> @@ -2102,7 +2102,7 @@ sub get_main_source_dir($$$) {
>          return $tempdir;
>      }
>      print "-- Move files to subdirectory $pkg-$newversion.\n" if $verbose;
> -    $main_source_dir = $tempdir . '/' . $pkg . '-' . $newversion ;
> +    $main_source_dir = $tempdir . '/' . $pkg . '-' . $newversion . $excludesuffix . '.orig';
>      mkdir($main_source_dir) or die("Unable to create temporary source directory $main_source_dir\n");
>      foreach my $file (@files) {
>  	unless ($file =~ /^\.\.?/) {
> -- 
> 1.7.10.4
> 

> From 482540af9ac9e8783a1ae85eac63965f60a2cbbd Mon Sep 17 00:00:00 2001
> From: gregor herrmann <gregoa@debian.org>
> Date: Sat, 25 Aug 2012 14:41:18 +0200
> Subject: [PATCH 4/5] add support for .jar
> 
> ---
>  scripts/uscan.pl |    8 ++++----
>  1 file changed, 4 insertions(+), 4 deletions(-)
> 
> diff --git a/scripts/uscan.pl b/scripts/uscan.pl
> index cb29f44..0bab138 100755
> --- a/scripts/uscan.pl
> +++ b/scripts/uscan.pl
> @@ -1410,7 +1410,7 @@ EOF
>  	$newfile_base = $newfile_base_gz;
>      }
>  
> -    if ($repack and $newfile_base =~ /^(.*)\.zip$/) {
> +    if ($repack and $newfile_base =~ /^(.*)\.(zip|jar)$/) {
>  	print "-- Repacking from zip to .tar.gz\n" if $verbose;
>  
>  	system('command -v unzip >/dev/null 2>&1') >> 8 == 0
> @@ -1422,12 +1422,12 @@ EOF
>  	my $hidden = ".[!.]*";
>  	my $absdestdir = abs_path($destdir);
>  	system('unzip', '-q', '-a', '-d', $tempdir, "$destdir/$newfile_base") == 0
> -	  or die("Repacking from zip to tar.gz failed (could not unzip)\n");
> +	  or die("Repacking from zip or jar to tar.gz failed (could not unzip)\n");
>  	if (defined glob("$tempdir/$hidden")) {
>  	    $globpattern .= " $hidden";
>  	}
>  	system("cd $tempdir; GZIP='-n -9' tar --owner=root --group=root --mode=a+rX -czf \"$absdestdir/$newfile_base_gz\" $globpattern") == 0
> -	  or die("Repacking from zip to tar.gz failed (could not create tarball)\n");
> +	  or die("Repacking from zip or jar to tar.gz failed (could not create tarball)\n");
>  	unlink "$destdir/$newfile_base";
>  	$newfile_base = $newfile_base_gz;
>      }
> @@ -1463,7 +1463,7 @@ EOF
>                  system('command -v unzip >/dev/null 2>&1') >> 8 == 0
>                     or die("unzip binary not found. This would serve as fallback because tar just failed.\n");
>                  system('unzip', '-q', '-a', '-d', $tempdir, "$destdir/$newfile_base") == 0
> -                   or die("Repacking from zip to tar.gz failed (could not unzip)\n");
> +                   or die("Repacking from zip or jar to tar.gz failed (could not unzip)\n");
>              }
>              my $excludesuffix = '+dfsg' ;
>              my $main_source_dir = get_main_source_dir($tempdir, $pkg, $newversion, $excludesuffix);
> -- 
> 1.7.10.4
> 

> From f85b9c16db8e388cd6a62fbe8e8aabe9ef082c99 Mon Sep 17 00:00:00 2001
> From: gregor herrmann <gregoa@debian.org>
> Date: Sat, 25 Aug 2012 14:52:01 +0200
> Subject: [PATCH 5/5] Output messages about the files-excluding action.
> 
> ---
>  scripts/uscan.pl |   10 ++++++++--
>  1 file changed, 8 insertions(+), 2 deletions(-)
> 
> diff --git a/scripts/uscan.pl b/scripts/uscan.pl
> index 0bab138..ba458ea 100755
> --- a/scripts/uscan.pl
> +++ b/scripts/uscan.pl
> @@ -1443,6 +1443,7 @@ EOF
>  	}
>      }
>  
> +    my $excludesuffix = '+dfsg';
>      if ( !$no_exclusion ) {
>          my $data = Dpkg::Control::Hash->new();
>          $data->load('debian/copyright');
> @@ -1465,7 +1466,6 @@ EOF
>                  system('unzip', '-q', '-a', '-d', $tempdir, "$destdir/$newfile_base") == 0
>                     or die("Repacking from zip or jar to tar.gz failed (could not unzip)\n");
>              }
> -            my $excludesuffix = '+dfsg' ;
>              my $main_source_dir = get_main_source_dir($tempdir, $pkg, $newversion, $excludesuffix);
>              unless ( -d $main_source_dir ) {
>                  print STDERR "Error: $main_source_dir is no directory";
> @@ -1488,7 +1488,7 @@ EOF
>                  my $newfile_base_dfsg = "${pkg}_${newversion}${excludesuffix}.orig.tar.$suffix" ;
>                  system("cd $tempdir; GZIP='-n -9' tar --owner=root --group=root --mode=a+rX -czf \"$absdestdir/$newfile_base_dfsg\" $globpattern") == 0
>                     or die("Excluding files failed (could not create tarball)\n");
> -                $symlink = 'no' # prevent symlinking or renaming
> +                $symlink = 'files-excluded' # prevent symlinking or renaming
>              }
>          }
>      }
> @@ -1519,6 +1519,8 @@ EOF
>  		print "    and symlinked $renamed_base to it\n";
>  	    } elsif ($symlink eq 'rename') {
>  		print "    and renamed it as $renamed_base\n";
> +	    } elsif ($symlink eq 'files-excluded') {
> +		print "    and removed files from it in ${pkg}_${newversion}${excludesuffix}.orig.tar.$suffix\n";
>  	    }
>  	} elsif ($dehs) {
>  	    my $msg = "Successfully downloaded updated package $newfile_base";
> @@ -1527,6 +1529,8 @@ EOF
>  		$msg .= " and symlinked $renamed_base to it";
>  	    } elsif ($symlink eq 'rename') {
>  		$msg .= " and renamed it as $renamed_base";
> +	    } elsif ($symlink eq 'files-excluded') {
> +		$msg .= " and removed files from it in ${pkg}_${newversion}${excludesuffix}.orig.tar.$suffix\n";
>  	    } else {
>  		$dehs_tags{'target'} = $newfile_base;
>  	    }
> @@ -1537,6 +1541,8 @@ EOF
>  		print "    and symlinked $renamed_base to it\n";
>  	    } elsif ($symlink eq 'rename') {
>  		print "    and renamed it as $renamed_base\n";
> +	    } elsif ($symlink eq 'files-excluded') {
> +		print "    and removed files from it in ${pkg}_${newversion}${excludesuffix}.orig.tar.$suffix\n";
>  	    }
>  	}
>  	last;
> -- 
> 1.7.10.4
> 




-- 
http://fam-tille.de
[0001-Undo-one-part-of-Gregor-s-changes.-It-is-not-safe-to.patch (text/x-diff, attachment)]

Information forwarded to debian-bugs-dist@lists.debian.org, Devscripts Devel Team <devscripts-devel@lists.alioth.debian.org>:
Bug#685787; Package devscripts. (Sun, 26 Aug 2012 18:09:03 GMT) Full text and rfc822 format available.

Acknowledgement sent to gregor herrmann <gregoa@debian.org>:
Extra info received and forwarded to list. Copy sent to Devscripts Devel Team <devscripts-devel@lists.alioth.debian.org>. (Sun, 26 Aug 2012 18:09:03 GMT) Full text and rfc822 format available.

Message #35 received at 685787@bugs.debian.org (full text, mbox):

From: gregor herrmann <gregoa@debian.org>
To: Andreas Tille <tille@debian.org>
Cc: 685787@bugs.debian.org
Subject: Re: Bug#685787: devscripts: Enabling uscan to simply remove files from upstream source
Date: Sun, 26 Aug 2012 20:08:06 +0200
[Message part 1 (text/plain, inline)]
On Sun, 26 Aug 2012 15:30:44 +0200, Andreas Tille wrote:

> I reverted one single line in your patch because this would break one of
> my test cases namely
> 
>    Vcs-Svn: svn://svn.debian.org/debian-med/trunk/packages/saint/trunk/
> 
> and does not fit my intention.  You tried to check whether upstream might
> contain a dir /^$pkg\w*$newversion$excludesuffix\.orig$/ which is most
> probably never the case (why should upstream name something ".orig"?).

Perfectly fine with me.
I was not 100% sure what your intention was in this part of the code
and just tried to get it the same as with my other changes :)

Cheers,
gregor
 
-- 
 .''`.  Homepage: http://info.comodo.priv.at/ - OpenPGP key 0xBB3A68018649AA06
 : :' : Debian GNU/Linux user, admin, and developer  -  http://www.debian.org/
 `. `'  Member of VIBE!AT & SPI, fellow of the Free Software Foundation Europe
   `-   NP: Schmetterlinge: Lied von der letzten Schlacht
[signature.asc (application/pgp-signature, inline)]

Information forwarded to debian-bugs-dist@lists.debian.org, Devscripts Devel Team <devscripts-devel@lists.alioth.debian.org>:
Bug#685787; Package devscripts. (Sun, 26 Aug 2012 18:33:05 GMT) Full text and rfc822 format available.

Acknowledgement sent to James McCoy <jamessan@debian.org>:
Extra info received and forwarded to list. Copy sent to Devscripts Devel Team <devscripts-devel@lists.alioth.debian.org>. (Sun, 26 Aug 2012 18:33:05 GMT) Full text and rfc822 format available.

Message #40 received at 685787@bugs.debian.org (full text, mbox):

From: James McCoy <jamessan@debian.org>
To: Andreas Tille <tille@debian.org>, 685787@bugs.debian.org
Cc: gregor herrmann <gregoa@debian.org>
Subject: Re: Bug#685787: devscripts: Enabling uscan to simply remove files from upstream source
Date: Sun, 26 Aug 2012 14:29:37 -0400
[Message part 1 (text/plain, inline)]
Thanks to both of you for working on this functionality.  The patches so
far look good.

On Sun, Aug 26, 2012 at 03:30:44PM +0200, Andreas Tille wrote:
> I attached another Git formated patch and repeat my question whether
> it might make sense to directly commit to the devscripts repository.

We can just as easily pull from another git repository
(e.g., git.debian.org/users/tille/devscripts.git) when we're ready to
merge the patches.  I'd really rather not have features being added
right now since we're in a freeze and that makes it harder to prepare
Wheezy-targeted uploads.

Cheers,
-- 
James
GPG Key: 4096R/331BA3DB 2011-12-05 James McCoy <jamessan@debian.org>
[signature.asc (application/pgp-signature, inline)]

Information forwarded to debian-bugs-dist@lists.debian.org, Devscripts Devel Team <devscripts-devel@lists.alioth.debian.org>:
Bug#685787; Package devscripts. (Sun, 26 Aug 2012 21:24:05 GMT) Full text and rfc822 format available.

Acknowledgement sent to Andreas Tille <tille@debian.org>:
Extra info received and forwarded to list. Copy sent to Devscripts Devel Team <devscripts-devel@lists.alioth.debian.org>. (Sun, 26 Aug 2012 21:24:05 GMT) Full text and rfc822 format available.

Message #45 received at 685787@bugs.debian.org (full text, mbox):

From: Andreas Tille <tille@debian.org>
To: James McCoy <jamessan@debian.org>
Cc: 685787@bugs.debian.org, gregor herrmann <gregoa@debian.org>
Subject: Re: Bug#685787: devscripts: Enabling uscan to simply remove files from upstream source
Date: Sun, 26 Aug 2012 23:19:51 +0200
[Message part 1 (text/plain, inline)]
Hi James,

On Sun, Aug 26, 2012 at 02:29:37PM -0400, James McCoy wrote:
> 
> We can just as easily pull from another git repository
> (e.g., git.debian.org/users/tille/devscripts.git) when we're ready to
> merge the patches.

OK, I'll consider this.

> I'd really rather not have features being added
> right now since we're in a freeze and that makes it harder to prepare
> Wheezy-targeted uploads.

Sounds reasonable.  However, I was hoping for a not so delayed upload to
experimental but for sure I'll leave the decision to you as the main
coders of devscripts.

Kind regards

      Andreas.

PS: I attach the next patch which became evident when trying with
    Vcs-Svn: svn://svn.debian.org/debian-med/trunk/packages/libpal-java/trunk/

-- 
http://fam-tille.de
[0001-Perls-move-function-is-unreliable-when-moving-direct.patch (text/x-diff, attachment)]

Information forwarded to debian-bugs-dist@lists.debian.org, Devscripts Devel Team <devscripts-devel@lists.alioth.debian.org>:
Bug#685787; Package devscripts. (Mon, 27 Aug 2012 19:45:05 GMT) Full text and rfc822 format available.

Acknowledgement sent to Andreas Tille <tille@debian.org>:
Extra info received and forwarded to list. Copy sent to Devscripts Devel Team <devscripts-devel@lists.alioth.debian.org>. (Mon, 27 Aug 2012 19:45:05 GMT) Full text and rfc822 format available.

Message #50 received at 685787@bugs.debian.org (full text, mbox):

From: Andreas Tille <tille@debian.org>
To: James McCoy <jamessan@debian.org>
Cc: 685787@bugs.debian.org, gregor herrmann <gregoa@debian.org>
Subject: Re: Bug#685787: devscripts: Enabling uscan to simply remove files from upstream source
Date: Mon, 27 Aug 2012 21:40:18 +0200
Hi,

On Sun, Aug 26, 2012 at 02:29:37PM -0400, James McCoy wrote:
> Thanks to both of you for working on this functionality.  The patches so
> far look good.
> 
> On Sun, Aug 26, 2012 at 03:30:44PM +0200, Andreas Tille wrote:
> > I attached another Git formated patch and repeat my question whether
> > it might make sense to directly commit to the devscripts repository.
> 
> We can just as easily pull from another git repository
> (e.g., git.debian.org/users/tille/devscripts.git) when we're ready to
> merge the patches.

My latest patches are now in

    git://git.debian.org/git/users/tille/devscripts.git

I wonder how I can enable people like gregor to commit to this repository.

Kind regards

      Andreas.

-- 
http://fam-tille.de



Information stored :
Bug#685787; Package devscripts. (Thu, 30 Aug 2012 15:18:09 GMT) Full text and rfc822 format available.

Acknowledgement sent to gregor herrmann <gregoa@debian.org>:
Extra info received and filed, but not forwarded. (Thu, 30 Aug 2012 15:18:09 GMT) Full text and rfc822 format available.

Message #55 received at 685787-quiet@bugs.debian.org (full text, mbox):

From: gregor herrmann <gregoa@debian.org>
To: Andreas Tille <tille@debian.org>
Cc: James McCoy <jamessan@debian.org>, 685787-quiet@bugs.debian.org
Subject: Re: Bug#685787: devscripts: Enabling uscan to simply remove files from upstream source
Date: Thu, 30 Aug 2012 17:15:53 +0200
[Message part 1 (text/plain, inline)]
On Mon, 27 Aug 2012 21:40:18 +0200, Andreas Tille wrote:

> > > I attached another Git formated patch and repeat my question whether
> > > it might make sense to directly commit to the devscripts repository.
> > We can just as easily pull from another git repository
> > (e.g., git.debian.org/users/tille/devscripts.git) when we're ready to
> > merge the patches.
> My latest patches are now in
>     git://git.debian.org/git/users/tille/devscripts.git
> I wonder how I can enable people like gregor to commit to this repository.

I guess the typical git-ish answer would be that everyone sets up
their own git repo and then everyone can
pull/merge/cherrypick/whatnot from everybody else's repo :)


Cheers,
gregor
 
-- 
 .''`.  Homepage: http://info.comodo.priv.at/ - OpenPGP key 0xBB3A68018649AA06
 : :' : Debian GNU/Linux user, admin, and developer  -  http://www.debian.org/
 `. `'  Member of VIBE!AT & SPI, fellow of the Free Software Foundation Europe
   `-   NP: Joel Harrison: Will the circle be unbroken
[signature.asc (application/pgp-signature, inline)]

Information forwarded to debian-bugs-dist@lists.debian.org, Devscripts Devel Team <devscripts-devel@lists.alioth.debian.org>:
Bug#685787; Package devscripts. (Sun, 02 Sep 2012 00:27:03 GMT) Full text and rfc822 format available.

Acknowledgement sent to Benjamin Drung <bdrung@debian.org>:
Extra info received and forwarded to list. Copy sent to Devscripts Devel Team <devscripts-devel@lists.alioth.debian.org>. (Sun, 02 Sep 2012 00:27:03 GMT) Full text and rfc822 format available.

Message #60 received at 685787@bugs.debian.org (full text, mbox):

From: Benjamin Drung <bdrung@debian.org>
To: 685787@bugs.debian.org
Cc: Andreas Tille <tille@debian.org>, gregor herrmann <gregoa@debian.org>
Subject: Re: Bug#685787: devscripts: Enabling uscan to simply remove files from upstream source
Date: Sun, 02 Sep 2012 02:25:46 +0200
[Message part 1 (text/plain, inline)]
Am Sonntag, den 26.08.2012, 14:29 -0400 schrieb James McCoy:
> Thanks to both of you for working on this functionality.  The patches so
> far look good.
> 
> On Sun, Aug 26, 2012 at 03:30:44PM +0200, Andreas Tille wrote:
> > I attached another Git formated patch and repeat my question whether
> > it might make sense to directly commit to the devscripts repository.
> 
> We can just as easily pull from another git repository
> (e.g., git.debian.org/users/tille/devscripts.git) when we're ready to
> merge the patches.  I'd really rather not have features being added
> right now since we're in a freeze and that makes it harder to prepare
> Wheezy-targeted uploads.

The current changes in our git repository fix two bugs and I like to get
these fixes into wheezy. The new script origtargz was also added and I
dunno if this scripts prevents us from getting the fixes into wheezy.
Maybe we should move origtargz into an experimental branch.

You could push your uscan changes into an 'experimental' branch in our
git repository if you want.

Before merging your changes into the master branch after the release of
wheezy, I like to see test cases to demonstrate the correct functioning.
Adding test cases is extra work in the beginning, but will pay off
later. devscripts comes with an growing test suite in tests/. The test
suite uses shunit2.

There is currently one test for uscan, but this is an online test. It
would be great if uscan could be modified to work locally for the tests.
This requires more Perl foo than I currently have.

You might want to look an DPU [1]. It is a test framework for Debian
tools and might be useful for us.

[1] http://blog.pault.ag/post/30552124986/a-bit-more-on-dpu

-- 
Benjamin Drung
Debian & Ubuntu Developer
[signature.asc (application/pgp-signature, inline)]

Information forwarded to debian-bugs-dist@lists.debian.org, Devscripts Devel Team <devscripts-devel@lists.alioth.debian.org>:
Bug#685787; Package devscripts. (Sun, 02 Sep 2012 06:21:03 GMT) Full text and rfc822 format available.

Acknowledgement sent to Andreas Tille <tille@debian.org>:
Extra info received and forwarded to list. Copy sent to Devscripts Devel Team <devscripts-devel@lists.alioth.debian.org>. (Sun, 02 Sep 2012 06:21:04 GMT) Full text and rfc822 format available.

Message #65 received at 685787@bugs.debian.org (full text, mbox):

From: Andreas Tille <tille@debian.org>
To: Benjamin Drung <bdrung@debian.org>
Cc: 685787@bugs.debian.org, gregor herrmann <gregoa@debian.org>
Subject: Re: Bug#685787: devscripts: Enabling uscan to simply remove files from upstream source
Date: Sun, 2 Sep 2012 08:14:11 +0200
Hi Benjamin,

On Sun, Sep 02, 2012 at 02:25:46AM +0200, Benjamin Drung wrote:
> 
> The current changes in our git repository fix two bugs and I like to get
> these fixes into wheezy. The new script origtargz was also added and I
> dunno if this scripts prevents us from getting the fixes into wheezy.
> Maybe we should move origtargz into an experimental branch.

I personally have no idea how release team will handle this.

> You could push your uscan changes into an 'experimental' branch in our
> git repository if you want.

While this would also have been a possibility I now followed previous
advise and use

  git://git.debian.org/git/users/tille/devscripts.git

> Before merging your changes into the master branch after the release of
> wheezy, I like to see test cases to demonstrate the correct functioning.
> Adding test cases is extra work in the beginning, but will pay off
> later. devscripts comes with an growing test suite in tests/. The test
> suite uses shunit2.

While I agree that having such test cases would be nice I admit that I
do not feel fit for this and would need help.  I'm testing my changes
for uscan by migrating Debian Med teams get-orig-source scripts to the
files-excluded method and verify that the result will remain the same
(or even more reasonable if the get-orig-script was not optimal.)
 
> There is currently one test for uscan, but this is an online test. It
> would be great if uscan could be modified to work locally for the tests.
> This requires more Perl foo than I currently have.

Please safely assume that my Perl foo is below yours. :-)
 
> You might want to look an DPU [1]. It is a test framework for Debian
> tools and might be useful for us.

Thanks for the hint, but I hope for the help of others to follow this
advise.

Kind regards

      Andreas.

-- 
http://fam-tille.de



Marked as found in versions devscripts/2.10.69. Request was from James McCoy <jamessan@debian.org> to control@bugs.debian.org. (Sat, 15 Sep 2012 00:15:04 GMT) Full text and rfc822 format available.

Information forwarded to debian-bugs-dist@lists.debian.org, Devscripts Devel Team <devscripts-devel@lists.alioth.debian.org>:
Bug#685787; Package devscripts. (Tue, 18 Dec 2012 17:39:03 GMT) Full text and rfc822 format available.

Acknowledgement sent to Csillag Tamas <cstamas@digitus.itk.ppke.hu>:
Extra info received and forwarded to list. Copy sent to Devscripts Devel Team <devscripts-devel@lists.alioth.debian.org>. (Tue, 18 Dec 2012 17:39:03 GMT) Full text and rfc822 format available.

Message #72 received at 685787@bugs.debian.org (full text, mbox):

From: Csillag Tamas <cstamas@digitus.itk.ppke.hu>
To: 685787@bugs.debian.org
Cc: gregor herrmann <gregoa@debian.org>
Subject: return the repacked filename instead the original
Date: Tue, 18 Dec 2012 18:28:48 +0100
Hi,

I include a one line patch which returns the name of the modified (repacked,
file excluded) tarball. This make uscan suitable for use with git-import-orig
(and others) without this they just silently work on the original untouched
tarball which in unintended.

The patch is based on the work already available at
git://git.debian.org/git/users/tille/devscripts.git

This all is part of a bigger picture (for me) which I documented here:
http://cstamas.hu/blog/posts/Standard_mechanism_for_repacking_upstream_tarballs_in_debian/

-------------------------------------------
From 744a59c5ac09ff2204fd0c95402362101d1c91b8 Mon Sep 17 00:00:00 2001
From: CSILLAG Tamas <cstamas@digitus.itk.ppke.hu>
Date: Tue, 18 Dec 2012 18:11:45 +0100
Subject: [PATCH] return the modified name in target

    The returned target value is updated to the right repacked file.
---
 scripts/uscan.pl |    1 +
 1 file changed, 1 insertion(+)

diff --git a/scripts/uscan.pl b/scripts/uscan.pl
index 7372ede..051e09f 100755
--- a/scripts/uscan.pl
+++ b/scripts/uscan.pl
@@ -1561,6 +1561,7 @@ EOF
 		$msg .= " and renamed it as $renamed_base";
 	    } elsif ($symlink eq 'files-excluded') {
 		$msg .= " and removed files from it in ${pkg}_${newversion}${excludesuffix}.orig.tar.$suffix\n";
+                $dehs_tags{'target'}                = "${pkg}_${newversion}${excludesuffix}.orig.tar.$suffix";
 	    } else {
 		$dehs_tags{'target'} = $newfile_base;
 	    }
-- 
1.7.10.4

-------------------------------------------

Regards,
  cstamas
-- 
CSILLAG Tamas (cstamas) - http://cstamas.hu/




Information forwarded to debian-bugs-dist@lists.debian.org, Devscripts Devel Team <devscripts-devel@lists.alioth.debian.org>:
Bug#685787; Package devscripts. (Mon, 28 Oct 2013 21:15:04 GMT) Full text and rfc822 format available.

Acknowledgement sent to Andreas Tille <tille@debian.org>:
Extra info received and forwarded to list. Copy sent to Devscripts Devel Team <devscripts-devel@lists.alioth.debian.org>. (Mon, 28 Oct 2013 21:15:04 GMT) Full text and rfc822 format available.

Message #77 received at 685787@bugs.debian.org (full text, mbox):

From: Andreas Tille <tille@debian.org>
To: Rafael Laboissiere <rafael@laboissiere.net>
Cc: 685787@bugs.debian.org
Subject: Re: Praat has serious bug #713597
Date: Mon, 28 Oct 2013 22:10:00 +0100
[Message part 1 (text/plain, inline)]
[Bug #685787:  Short background: Rafael volunteered to check the
 difference between the branch of devscripts at
   http://anonscm.debian.org/gitweb/?p=users/tille/devscripts.git;a=summary
 done at 2012-08-26 to provide a handy way for a patch (according
 to some of the various hints I've got to my proposal.]

Hi Rafael,

On Mon, Oct 28, 2013 at 07:44:57PM +0100, Rafael Laboissiere wrote:
> >Ok, I will take a look at it.
> 
> I did a 3-way merge using the versions of uscan.pl at master in both
> repositories and the common ancestor of them.  The resulting script
> is attached below.  It works for me in the praat package, but I did
> not tested it elsewhere.

Thanks.

> FYI, I am also attaching the diffs with the versions at master in
> both yours (uscan.pl.diff-tille) and the developer's repositories.

Good.

> It would be preferable that you had created a side branch in the Git
> repository for your changes, such that the merge would be trivial to
> do.

While seeing it now (14 monthes later since I started the branch) this
would have been probably better.  In the (longish) discussion I was
advised to do so because this was somehow the "usual" way to go since
Git would provide that great merging features (I'm remaining at very
beginner level regarding Git) and it was not intended at all to take
that long. :-(

> I think that the best thing to do now is to generated a Git
> patch against the main repository's master version and propose it to
> the developers. What do you think?

Most probably.  Specifically I think it makes sense to publish your
diffs in the according bug report to make sure it appears somewhere
online.

> It will also be necessary to prepare a qpatched versions for uscan.1
> and debian/control.

I'd happily provide this if I could be sure that this effort is not
wasted in a way that uscan in devscripts simply moves on and I need
to redo the patch later again.  Some signal of devscripts maintainer
regarding this would be helpful.

> BTW, I think that we should add Recommends:
> libtry-tiny-perl libdpkg-perl

That's correct. 

Kind regards

       Andreas.

-- 
http://fam-tille.de
[uscan.pl (text/x-perl, attachment)]
[uscan.pl.diff-debian (text/plain, attachment)]
[uscan.pl.diff-tille (text/plain, attachment)]

Information forwarded to debian-bugs-dist@lists.debian.org, Devscripts Devel Team <devscripts-devel@lists.alioth.debian.org>:
Bug#685787; Package devscripts. (Mon, 28 Oct 2013 23:09:04 GMT) Full text and rfc822 format available.

Acknowledgement sent to James McCoy <jamessan@debian.org>:
Extra info received and forwarded to list. Copy sent to Devscripts Devel Team <devscripts-devel@lists.alioth.debian.org>. (Mon, 28 Oct 2013 23:09:04 GMT) Full text and rfc822 format available.

Message #82 received at 685787@bugs.debian.org (full text, mbox):

From: James McCoy <jamessan@debian.org>
To: Andreas Tille <tille@debian.org>, 685787@bugs.debian.org
Cc: Rafael Laboissiere <rafael@laboissiere.net>
Subject: Re: Bug#685787: Praat has serious bug #713597
Date: Mon, 28 Oct 2013 19:06:37 -0400
[Message part 1 (text/plain, inline)]
Thanks Rafael for the feedback and Andreas for continued patience.

On Mon, Oct 28, 2013 at 10:10:00PM +0100, Andreas Tille wrote:
> On Mon, Oct 28, 2013 at 07:44:57PM +0100, Rafael Laboissiere wrote:
> > It would be preferable that you had created a side branch in the Git
> > repository for your changes, such that the merge would be trivial to
> > do.

This really wouldn't have made much of a difference.  It's trivial to
add Andrea's repo as a remote and then the functionality is the same as
if the branch were in devscripts' repo.  At the time that Andreas
started work on this, devscripts wasn't in collab-maint so it made sense
to just push his changes to a user repo on Alioth so people could access
and review the changes.

> > It will also be necessary to prepare a qpatched versions for uscan.1
> > and debian/control.
> 
> I'd happily provide this if I could be sure that this effort is not
> wasted in a way that uscan in devscripts simply moves on and I need
> to redo the patch later again.  Some signal of devscripts maintainer
> regarding this would be helpful.

As stated before, we were originally waiting for the (longish) Wheezy
freeze to finish and release.  Since that has happened, there has been a
lack of time available from existing maintainers.

Your work is not wasted, though, since we can integrate your changes
regardless of whether they've been rebased on a recent version of uscan.
It's "just" a matter of time to review and merge.

I will work on this within the next month.

Cheers,
-- 
James
GPG Key: 4096R/331BA3DB 2011-12-05 James McCoy <jamessan@debian.org>
[signature.asc (application/pgp-signature, inline)]

Information forwarded to debian-bugs-dist@lists.debian.org, Devscripts Devel Team <devscripts-devel@lists.alioth.debian.org>:
Bug#685787; Package devscripts. (Tue, 29 Oct 2013 09:36:21 GMT) Full text and rfc822 format available.

Acknowledgement sent to Andreas Tille <tille@debian.org>:
Extra info received and forwarded to list. Copy sent to Devscripts Devel Team <devscripts-devel@lists.alioth.debian.org>. (Tue, 29 Oct 2013 09:36:21 GMT) Full text and rfc822 format available.

Message #87 received at 685787@bugs.debian.org (full text, mbox):

From: Andreas Tille <tille@debian.org>
To: James McCoy <jamessan@debian.org>
Cc: 685787@bugs.debian.org, Rafael Laboissiere <rafael@laboissiere.net>
Subject: Re: Bug#685787: Praat has serious bug #713597
Date: Tue, 29 Oct 2013 10:33:52 +0100
Hi James,

On Mon, Oct 28, 2013 at 07:06:37PM -0400, James McCoy wrote:
> Thanks Rafael for the feedback and Andreas for continued patience.
> 
> On Mon, Oct 28, 2013 at 10:10:00PM +0100, Andreas Tille wrote:
> > On Mon, Oct 28, 2013 at 07:44:57PM +0100, Rafael Laboissiere wrote:
> > > It would be preferable that you had created a side branch in the Git
> > > repository for your changes, such that the merge would be trivial to
> > > do.
> 
> This really wouldn't have made much of a difference.  It's trivial to
> add Andrea's repo as a remote and then the functionality is the same as
> if the branch were in devscripts' repo.  At the time that Andreas
> started work on this, devscripts wasn't in collab-maint so it made sense
> to just push his changes to a user repo on Alioth so people could access
> and review the changes.

OK.

> > > It will also be necessary to prepare a qpatched versions for uscan.1
> > > and debian/control.
> > 
> > I'd happily provide this if I could be sure that this effort is not
> > wasted in a way that uscan in devscripts simply moves on and I need
> > to redo the patch later again.  Some signal of devscripts maintainer
> > regarding this would be helpful.
> 
> As stated before, we were originally waiting for the (longish) Wheezy
> freeze to finish and release.  Since that has happened, there has been a
> lack of time available from existing maintainers.
> 
> Your work is not wasted, though, since we can integrate your changes
> regardless of whether they've been rebased on a recent version of uscan.
> It's "just" a matter of time to review and merge.
> 
> I will work on this within the next month.

Cool.  Just let me know if I could be of any help.

Kind regards and thanks for maintaining devscripts

      Andreas.

-- 
http://fam-tille.de



Information forwarded to debian-bugs-dist@lists.debian.org, Devscripts Devel Team <devscripts-devel@lists.alioth.debian.org>:
Bug#685787; Package devscripts. (Tue, 29 Oct 2013 09:42:05 GMT) Full text and rfc822 format available.

Acknowledgement sent to Andreas Tille <tille@debian.org>:
Extra info received and forwarded to list. Copy sent to Devscripts Devel Team <devscripts-devel@lists.alioth.debian.org>. (Tue, 29 Oct 2013 09:42:05 GMT) Full text and rfc822 format available.

Message #92 received at 685787@bugs.debian.org (full text, mbox):

From: Andreas Tille <tille@debian.org>
To: 685787@bugs.debian.org
Subject: [rafael@laboissiere.net: Re: Patch for devscripts]
Date: Tue, 29 Oct 2013 10:37:29 +0100
Hi again,

just to make sure that Rafael's work is propagated in case it might
help.  I understood James' mail and that he could work with the existing
Git repository but since Rafael did some style changes this patch might
be more clean.

Kind regards

      Andreas.

----- Forwarded message from Rafael Laboissiere <rafael@laboissiere.net> -----

Date: Tue, 29 Oct 2013 09:36:39 +0100
From: Rafael Laboissiere <rafael@laboissiere.net>
To: Andreas Tille <tille@debian.org>
Subject: Re: Patch for devscripts

* Andreas Tille <tille@debian.org> [2013-10-28 22:56]:
> 
> On Mon, Oct 28, 2013 at 10:37:13PM +0100, Rafael Laboissiere wrote:
>> 
>> If you agree, I can give it a try.  Remember that users of Git
>> appreciate when you play the Git rules.
> 
> For sure I agree!  On one hand this gives another pair of eyeballs
> looking at my crappy code.  On the other hand I can spent my time
> for other burning things in Debian Med.  So feel free to move on
> and ping me if you need any help.

Ok, I succeeded to isolate the changes related to Files-Excluded and
put them all into a single patch, which you will find attached below.
This patch applies cleanly to the current qdevscript repository's
master:

    git clone git://anonscm.debian.org/collab-maint/devscripts.git
    cd devscripts
    patch -p1 < /path/to/files-excluded.patch

The resulting uscan.pl script works fine for me (at least, for the
praat package).  Of course, it does not have the repack-compression
feature.

You will note that I did a couple of stylistic changes.  I also
removed those comments related to Parse::DebControl.  The goal is to
provide a slim patch, such that its chances to be accepted are higher.
I did not revise your Perl code in detail, though (since it ain't
broken, I won't fix it!).

In order to produce a proper Git patch you must give me a decent
commit message.  It does not need to be short.  On the contrary, it
must be quite clear on what has been changed.  I think that an
explanation as you gave in the report of Bug#685787 would be fine.

> Perhaps it makes sense to update the Wiki page about what's going on.

Probably, yes.

Best,

Rafael






diff --git a/debian/control b/debian/control
index d48f7f2..b9dc690 100644
--- a/debian/control
+++ b/debian/control
@@ -16,6 +16,7 @@ Build-Depends: debhelper (>= 9),
                libparse-debcontrol-perl,
                libterm-size-perl,
                libtimedate-perl,
+               libtry-tiny-perl,
                liburi-perl,
                libwww-perl,
                lsb-release,
@@ -50,6 +51,7 @@ Recommends: at,
             libencode-locale-perl,
             libjson-perl,
             libparse-debcontrol-perl,
+            libtry-tiny-perl,
             liburi-perl,
             libwww-perl,
             lintian,
diff --git a/scripts/uscan.1 b/scripts/uscan.1
index af4e57f..fb53f3e 100644
--- a/scripts/uscan.1
+++ b/scripts/uscan.1
@@ -444,6 +444,10 @@ Give verbose output.
 .B \-\-no\-verbose
 Don't give verbose output.  (This is the default behaviour.)
 .TP
+.B \-\-no\-exclusion
+Do not automatically exclude files mentioned in
+\fIdebian/copyright\fR field \fBFiles-Excluded\fR
+.TP
 .B \-\-debug
 Dump the downloaded web pages to stdout for debugging your watch file.
 .TP
@@ -517,6 +521,10 @@ equivalent to the \fB\-\-destdir\fR option.
 If this is set to \fIyes\fR, then after having downloaded a bzip tar,
 lzma tar, xz tar, or zip archive, \fBuscan\fR will repack it to a gzip tar.
 This is equivalent to the \fB\-\-repack\fR option.
+.B USCAN_NO_EXCLUSION
+If this is set to \fIyes\fR, files mentioned in the field \fBFiles-Excluded\fR
+of \fIdebian/copyright\fR will be ignored and no exclusion of files will be
+tried.  This is equivalent to the \fB\-\-no-exclusion\fR option.
 .SH "EXIT STATUS"
 The exit status gives some indication of whether a newer version was
 found or not; one is advised to read the output to determine exactly
diff --git a/scripts/uscan.pl b/scripts/uscan.pl
index 976b368..5dc8a6e 100755
--- a/scripts/uscan.pl
+++ b/scripts/uscan.pl
@@ -27,6 +27,8 @@ use strict;
 use Cwd;
 use Cwd 'abs_path';
 use Dpkg::IPC;
+use Dpkg::Control::Hash;
+use Try::Tiny;
 use File::Basename;
 use File::Copy;
 use File::Temp qw/tempfile tempdir/;
@@ -46,6 +48,7 @@ BEGIN {
 	}
     }
 }
+
 my $CURRENT_WATCHFILE_VERSION = 3;
 
 my $progname = basename($0);
@@ -72,6 +75,7 @@ sub uscan_die (@);
 sub dehs_output ();
 sub quoted_regex_replace ($);
 sub safe_replace ($$);
+sub get_main_source_dir ($$$$$);
 
 sub usage {
     print <<"EOF";
@@ -138,6 +142,8 @@ Options:
     --no-conf, --noconf
                    Don\'t read devscripts config files;
                    must be the first option given
+    --no-exclusion no automatic exclusion of files mentioned in
+                   debian/copyright field Files-Excluded
     --help         Show this message
     --version      Show version information
 
@@ -180,6 +186,7 @@ my $dehs_start_output = 0;
 my $pkg_report_header = '';
 my $timeout = 20;
 my $user_agent_string = 'Debian uscan ###VERSION###';
+my $no_exclusion = 0;
 
 if (@ARGV and $ARGV[0] =~ /^--no-?conf$/) {
     $modified_conf_msg = "  (no configuration files read)";
@@ -196,6 +203,7 @@ if (@ARGV and $ARGV[0] =~ /^--no-?conf$/) {
 		       'USCAN_DEHS_OUTPUT' => 'no',
 		       'USCAN_USER_AGENT' => '',
 		       'USCAN_REPACK' => 'no',
+		       'USCAN_NO_EXCLUSION' => 'no',
 		       'DEVSCRIPTS_CHECK_DIRNAME_LEVEL' => 1,
 		       'DEVSCRIPTS_CHECK_DIRNAME_REGEX' => 'PACKAGE(-.+)?',
 		       );
@@ -233,6 +241,8 @@ if (@ARGV and $ARGV[0] =~ /^--no-?conf$/) {
 	or $config_vars{'USCAN_DEHS_OUTPUT'}='no';
     $config_vars{'USCAN_REPACK'} =~ /^(yes|no)$/
 	or $config_vars{'USCAN_REPACK'}='no';
+    $config_vars{'USCAN_NO_EXCLUSION'} =~ /^(yes|no)$/
+	or $config_vars{'USCAN_NO_EXCLUSION'}='no';
     $config_vars{'DEVSCRIPTS_CHECK_DIRNAME_LEVEL'} =~ /^[012]$/
 	or $config_vars{'DEVSCRIPTS_CHECK_DIRNAME_LEVEL'}=1;
 
@@ -263,7 +273,7 @@ if (@ARGV and $ARGV[0] =~ /^--no-?conf$/) {
 # Now read the command line arguments
 my $debug = 0;
 my ($opt_h, $opt_v, $opt_destdir, $opt_download, $opt_force_download,
-    $opt_report, $opt_passive, $opt_symlink, $opt_repack);
+    $opt_report, $opt_passive, $opt_symlink, $opt_repack, $opt_no_exclusion);
 my ($opt_verbose, $opt_level, $opt_regex, $opt_noconf);
 my ($opt_package, $opt_uversion, $opt_watchfile, $opt_dehs, $opt_timeout);
 my $opt_download_version;
@@ -295,6 +305,7 @@ GetOptions("help" => \$opt_h,
 	   "useragent=s" => \$opt_user_agent,
 	   "noconf" => \$opt_noconf,
 	   "no-conf" => \$opt_noconf,
+	   "no-exclusion" => \$opt_no_exclusion,
 	   "download-current-version" => \$opt_download_current_version,
 	   )
     or die "Usage: $progname [options] [directories]\nRun $progname --help for more details\n";
@@ -318,6 +329,7 @@ $timeout = 20 unless defined $timeout and $timeout > 0;
 $symlink = $opt_symlink if defined $opt_symlink;
 $verbose = $opt_verbose if defined $opt_verbose;
 $dehs = $opt_dehs if defined $opt_dehs;
+$no_exclusion = $opt_no_exclusion if defined $opt_no_exclusion;
 $user_agent_string = $opt_user_agent if defined $opt_user_agent;
 $download_version = $opt_download_version if defined $opt_download_version;
 
@@ -1480,6 +1492,63 @@ EOF
 	}
     }
 
+    my $excludesuffix = '+dfsg';
+    if ( !$no_exclusion ) {
+        my $data ;
+        $data = Dpkg::Control::Hash->new();
+        try {
+            $data->load('debian/copyright');
+        } catch {
+            print "-- No machine readable debian/copyright file.\n" if ( $verbose ) ;
+            $data->{'format'} = '' ;
+        } ;
+        my $okformat = qr'http://www.debian.org/doc/packaging-manuals/copyright-format/[.\d]+';
+        print "-- Wrong format of debian/copyright file to profit from Files-Excluded.\n" if ( $data->{'files-excluded'} and $data->{'format'} !~ m{^$okformat/?$} and $verbose ) ;
+        if ($data->{'format'} =~ m{^$okformat/?$} and $data->{'files-excluded'} ) {
+            my $tempdir = tempdir ( "uscanXXXX", TMPDIR => 1, CLEANUP => 1 );
+            my $globpattern = "*";
+            my $hidden = ".[!.]*";
+            if (defined glob("$tempdir/$hidden")) {
+                $globpattern .= " $hidden";
+            }
+            my $absdestdir = abs_path($destdir);
+            unless ( system("cd $tempdir; tar -xaf \"$absdestdir/$newfile_base\" 2>/dev/null") == 0 ) {
+                print "-- $newfile_base is no tarball.  Try unzip.\n" if $verbose;
+                # try unzip if tar fails - we do want to do something sensible even if no --repack was specified
+                system('command -v unzip >/dev/null 2>&1') >> 8 == 0
+                   or die("unzip binary not found. This would serve as fallback because tar just failed.\n");
+                system('unzip', '-q', '-a', '-d', $tempdir, "$destdir/$newfile_base") == 0
+                   or die("Repacking from zip to tar.gz failed (could not unzip)\n");
+            }
+            # Some source archives contain a useless __MACOSX dir which would prevent a reasonable
+            # normalising of the +dfsg.orig archive - so removing it in advance in case it should
+            # be removed anyway helps creating normalised source archives.
+            my $exclude__MACOSX = grep( /\s*\/?__MACOSX\/?\s*/, $data->{"files-excluded"} );
+            my $main_source_dir = get_main_source_dir($tempdir, $pkg, $newversion, $excludesuffix, $exclude__MACOSX);
+            unless ( -d $main_source_dir ) {
+                print STDERR "Error: $main_source_dir is no directory";
+            }
+            my $nfiles_before = `find "$main_source_dir" | wc -l`;
+            foreach (split /\s+/, $data->{"files-excluded"}) {
+                # delete trailing '/' because otherwise find -path will fail
+                s?/+$?? ;
+                # use -depth to enable deleting directories
+                system('find',$main_source_dir,'-depth','-path',"$main_source_dir/$_",qw(-exec rm -rf {} ;))==0 or
+                    die "failure to run find properly";
+            };
+            my $nfiles_after = `find "$main_source_dir" | wc -l`;
+            if ( $nfiles_before == $nfiles_after && ! $exclude__MACOSX ) {
+                print "-- Source tree remains identical - no need for repacking.\n" if $verbose;
+            } else {
+                my $suffix = 'gz' ;
+                my $newfile_base_dfsg = "${pkg}_${newversion}${excludesuffix}.orig.tar.$suffix" ;
+                system("cd $tempdir; GZIP='-n -9' tar --owner=root --group=root --mode=a+rX -czf \"$absdestdir/$newfile_base_dfsg\" $globpattern") == 0
+                   or die("Excluding files failed (could not create tarball)\n");
+                $symlink = 'files-excluded' # prevent symlinking or renaming
+            }
+        }
+    }
+
     my @renames = (
 	[qr/\.(tar\.gz|tgz)$/, 'gz'],
 	[qr/\.(tar\.bz2|tbz2?)$/, 'bz2'],
@@ -1506,6 +1575,8 @@ EOF
 		print "    and symlinked $renamed_base to it\n";
 	    } elsif ($symlink eq 'rename') {
 		print "    and renamed it as $renamed_base\n";
+	    } elsif ($symlink eq 'files-excluded') {
+		print "    and removed files from it in ${pkg}_${newversion}${excludesuffix}.orig.tar.$suffix\n";
 	    }
 	} elsif ($dehs) {
 	    my $msg = "Successfully downloaded updated package $newfile_base";
@@ -1514,6 +1585,8 @@ EOF
 		$msg .= " and symlinked $renamed_base to it";
 	    } elsif ($symlink eq 'rename') {
 		$msg .= " and renamed it as $renamed_base";
+	    } elsif ($symlink eq 'files-excluded') {
+		$msg .= " and removed files from it in ${pkg}_${newversion}${excludesuffix}.orig.tar.$suffix\n";
 	    } else {
 		$dehs_tags{'target'} = $newfile_base;
 	    }
@@ -1524,6 +1597,8 @@ EOF
 		print "    and symlinked $renamed_base to it\n";
 	    } elsif ($symlink eq 'rename') {
 		print "    and renamed it as $renamed_base\n";
+	    } elsif ($symlink eq 'files-excluded') {
+		print "    and removed files from it in ${pkg}_${newversion}${excludesuffix}.orig.tar.$suffix\n";
 	    }
 	}
 	last;
@@ -2066,3 +2141,56 @@ sub safe_replace($$) {
 	return 1;
     }
 }
+
+sub get_main_source_dir($$$$$) {
+    my ($tempdir, $pkg, $newversion, $excludesuffix, $exclude__MACOSX) = @_;
+    my $fcount = 0;
+    my $main_source_dir = '' ;
+    my $any_dir = '' ;
+    opendir DIR, $tempdir or die "opendir $tempdir: $!";
+    my @files = readdir DIR ;
+    closedir DIR ;
+    foreach my $file (@files) {
+	unless ($file =~ /^\.\.?/) {
+            if ( $exclude__MACOSX && $file =~ /^__MACOSX$/ ) {
+                `rm -rf ${tempdir}/__MACOSX` ;
+                next ;
+            }
+            $fcount++;
+	    if ( -d $tempdir.'/'.$file ) {
+                $any_dir = $tempdir . '/' . $file ;
+                # check whether there is some dir in upstream source which looks reasonable
+                # If such dir exists, we do not try to undirty the directory structure
+                $main_source_dir = $any_dir if ( $file =~ /^$pkg\w*$newversion$/i ) ;
+            }
+        }
+    }
+    if ( $fcount == 1 and $main_source_dir ) {
+        return $main_source_dir ;
+    }
+    if ( $fcount == 1 and $any_dir ) {
+        # Unusual base dir in tarball - should be rather something like ${pkg}-${newversion}
+        $main_source_dir = $tempdir . '/' . $pkg . '-' . $newversion . $excludesuffix . '.orig';
+        move($any_dir, $main_source_dir) or die("Unable to move $any_dir directory $main_source_dir\n");
+        return $main_source_dir ;
+    }
+    print "-- Dirty tarball found.\n" if $verbose;
+    if ( $main_source_dir ) { # if tarball is dirty but does contain a $pkg-$newversion dir we will not undirty but leave it as is
+        print "-- No idea how to create proper tarball structure - leaving as is.\n" if $verbose;
+        return $tempdir;
+    }
+    print "-- Move files to subdirectory $pkg-$newversion.\n" if $verbose;
+    $main_source_dir = $tempdir . '/' . $pkg . '-' . $newversion . $excludesuffix . '.orig';
+    mkdir($main_source_dir) or die("Unable to create temporary source directory $main_source_dir\n");
+    foreach my $file (@files) {
+	unless ($file =~ /^\.\.?/) {
+	    if ( -d "${tempdir}/$file" ) {
+                # HELP: why can't perl move not move directories????
+                system( "mv ${tempdir}/$file $main_source_dir" ) ;
+            } else {
+                move("${tempdir}/$file", $main_source_dir) or die("Unable to move ${tempdir}/$file directory $main_source_dir\n");
+            }
+        }
+    }
+    return $main_source_dir;
+}


----- End forwarded message -----

-- 
http://fam-tille.de



Information forwarded to debian-bugs-dist@lists.debian.org, Devscripts Devel Team <devscripts-devel@lists.alioth.debian.org>:
Bug#685787; Package devscripts. (Wed, 30 Oct 2013 09:27:09 GMT) Full text and rfc822 format available.

Acknowledgement sent to Rafael Laboissiere <rafael@laboissiere.net>:
Extra info received and forwarded to list. Copy sent to Devscripts Devel Team <devscripts-devel@lists.alioth.debian.org>. (Wed, 30 Oct 2013 09:27:09 GMT) Full text and rfc822 format available.

Message #97 received at 685787@bugs.debian.org (full text, mbox):

From: Rafael Laboissiere <rafael@laboissiere.net>
To: Andreas Tille <tille@debian.org>
Cc: James McCoy <jamessan@debian.org>, 685787@bugs.debian.org
Subject: Re: Bug#685787: Praat has serious bug #713597
Date: Wed, 30 Oct 2013 09:45:51 +0100
[Message part 1 (text/plain, inline)]
* Andreas Tille <tille@debian.org> [2013-10-29 10:33]:

> On Mon, Oct 28, 2013 at 07:06:37PM -0400, James McCoy wrote:
>> Thanks Rafael for the feedback and Andreas for continued patience.
>>
>> On Mon, Oct 28, 2013 at 10:10:00PM +0100, Andreas Tille wrote:
>>> On Mon, Oct 28, 2013 at 07:44:57PM +0100, Rafael Laboissiere wrote:
>>>> It would be preferable that you had created a side branch in the Git
>>>> repository for your changes, such that the merge would be trivial to
>>>> do.
>>
>> This really wouldn't have made much of a difference.  It's trivial to 
>> add Andrea's repo as a remote and then the functionality is the same as 
>> if the branch were in devscripts' repo.  At the time that Andreas 
>> started work on this, devscripts wasn't in collab-maint so it made sense 
>> to just push his changes to a user repo on Alioth so people could access 
>> and review the changes.

For the convenience of the developers of devscript, I am attaching below 
a patch generated with git format-patch that contains an appropriate log 
message.  I cherry-picked the commits made by Andreas Tille and Gregor 
Herrmann into the Andreas' repo, which concern only the implementation of 
the Files-Excluded feature.  I did also some improvements on my own. his 
patch works for me on the praat package, but was not extensively tested. 
At any rate, this "slim" patch introduces a single feature, namely the 
possibility of excluding files from upstream tarballs according to 
information in debain/copyright.

If I had push access to the devscripts repository, I could create a 
side branch there with this patch.

Best,

Rafael

[uscan-files-excluded.patch (text/x-diff, attachment)]

Information forwarded to debian-bugs-dist@lists.debian.org, Devscripts Devel Team <devscripts-devel@lists.alioth.debian.org>:
Bug#685787; Package devscripts. (Fri, 01 Nov 2013 23:09:04 GMT) Full text and rfc822 format available.

Acknowledgement sent to Benjamin Drung <bdrung@debian.org>:
Extra info received and forwarded to list. Copy sent to Devscripts Devel Team <devscripts-devel@lists.alioth.debian.org>. (Fri, 01 Nov 2013 23:09:04 GMT) Full text and rfc822 format available.

Message #102 received at 685787@bugs.debian.org (full text, mbox):

From: Benjamin Drung <bdrung@debian.org>
To: Rafael Laboissiere <rafael@laboissiere.net>, 685787@bugs.debian.org
Cc: Andreas Tille <tille@debian.org>
Subject: Re: Bug#685787: Praat has serious bug #713597
Date: Sat, 02 Nov 2013 00:05:52 +0100
On Mi, 2013-10-30 at 09:45 +0100, Rafael Laboissiere wrote:
> * Andreas Tille <tille@debian.org> [2013-10-29 10:33]:
> 
> > On Mon, Oct 28, 2013 at 07:06:37PM -0400, James McCoy wrote:
> >> Thanks Rafael for the feedback and Andreas for continued patience.
> >>
> >> On Mon, Oct 28, 2013 at 10:10:00PM +0100, Andreas Tille wrote:
> >>> On Mon, Oct 28, 2013 at 07:44:57PM +0100, Rafael Laboissiere wrote:
> >>>> It would be preferable that you had created a side branch in the Git
> >>>> repository for your changes, such that the merge would be trivial to
> >>>> do.
> >>
> >> This really wouldn't have made much of a difference.  It's trivial to 
> >> add Andrea's repo as a remote and then the functionality is the same as 
> >> if the branch were in devscripts' repo.  At the time that Andreas 
> >> started work on this, devscripts wasn't in collab-maint so it made sense 
> >> to just push his changes to a user repo on Alioth so people could access 
> >> and review the changes.
> 
> For the convenience of the developers of devscript, I am attaching below 
> a patch generated with git format-patch that contains an appropriate log 
> message.  I cherry-picked the commits made by Andreas Tille and Gregor 
> Herrmann into the Andreas' repo, which concern only the implementation of 
> the Files-Excluded feature.  I did also some improvements on my own. his 
> patch works for me on the praat package, but was not extensively tested. 
> At any rate, this "slim" patch introduces a single feature, namely the 
> possibility of excluding files from upstream tarballs according to 
> information in debain/copyright.
> 
> If I had push access to the devscripts repository, I could create a 
> side branch there with this patch.

The patch looks good on a quick look. I haven't applied or tested it. I
leave the integration to James, who offered to work on it.

I have just one recommendation/wish: It would be nice if test cases
could be added for the new feature. The test cases should work offline.

-- 
Benjamin Drung
Debian & Ubuntu Developer




Information forwarded to debian-bugs-dist@lists.debian.org, Devscripts Devel Team <devscripts-devel@lists.alioth.debian.org>:
Bug#685787; Package devscripts. (Sat, 02 Nov 2013 11:06:04 GMT) Full text and rfc822 format available.

Acknowledgement sent to Rafael Laboissiere <rafael@laboissiere.net>:
Extra info received and forwarded to list. Copy sent to Devscripts Devel Team <devscripts-devel@lists.alioth.debian.org>. (Sat, 02 Nov 2013 11:06:04 GMT) Full text and rfc822 format available.

Message #107 received at 685787@bugs.debian.org (full text, mbox):

From: Rafael Laboissiere <rafael@laboissiere.net>
To: Benjamin Drung <bdrung@debian.org>
Cc: 685787@bugs.debian.org, Andreas Tille <tille@debian.org>
Subject: Re: Bug#685787: Praat has serious bug #713597
Date: Sat, 2 Nov 2013 12:03:39 +0100
[Message part 1 (text/plain, inline)]
* Benjamin Drung <bdrung@debian.org> [2013-11-02 00:05]:
>
> I have just one recommendation/wish: It would be nice if test cases 
> could be added for the new feature. The test cases should work offline.

Would something along the lines of the very simple-minded shell script 
attached below be appropriate?  Of course, it will need adaptation for 
the shunit2 framework used in devscripts.

What this script does is (1) create a minimal Debian package directory, 
containing minimal files debian/{changelog,watch,copyright}, (2) create a 
minimal repository, containing a tarball (built on the fly), and (3) 
start an HTTP server that works offline, using the SimpleHTTPServer 
module of Python.

When I run this with the modified uscan.pl, I obtain the following:

   foo/
   foo/exclude-this
   foo/include-this
   Serving HTTP on 0.0.0.0 port 8000 ...
   -- Scanning for watchfiles in .
   -- Found watchfile in ./debian
   -- In debian/watch, processing watchfile line:
      http://localhost:8000/foo-(\d).tar.gz
   127.0.0.1 - - [02/Nov/2013 08:27:16] "GET / HTTP/1.1" 200 -
   -- Found the following matching hrefs:
        foo-1.tar.gz (1)
   Newest version on remote site is 1, local version is 0
    => Newer version available from
       http://localhost:8000/foo-1.tar.gz
   -- Downloading updated package foo-1.tar.gz
   127.0.0.1 - - [02/Nov/2013 08:27:16] "GET /foo-1.tar.gz HTTP/1.1" 200 -
   -- Successfully downloaded updated package foo-1.tar.gz
       and removed files from it in foo_1+dfsg.orig.tar.gz
   -- Scan finished
   drwxr-xr-x root/root         0 2013-11-02 08:27 foo-1+dfsg.orig/
   -rw-r--r-- root/root         0 2013-11-02 08:27 foo-1+dfsg.orig/include-this

Best,

Rafael

[test-uscan-files-excluded.sh (application/x-sh, attachment)]

Information forwarded to debian-bugs-dist@lists.debian.org, Devscripts Devel Team <devscripts-devel@lists.alioth.debian.org>:
Bug#685787; Package devscripts. (Sat, 02 Nov 2013 12:09:04 GMT) Full text and rfc822 format available.

Acknowledgement sent to Benjamin Drung <bdrung@debian.org>:
Extra info received and forwarded to list. Copy sent to Devscripts Devel Team <devscripts-devel@lists.alioth.debian.org>. (Sat, 02 Nov 2013 12:09:04 GMT) Full text and rfc822 format available.

Message #112 received at 685787@bugs.debian.org (full text, mbox):

From: Benjamin Drung <bdrung@debian.org>
To: Rafael Laboissiere <rafael@laboissiere.net>
Cc: 685787@bugs.debian.org, Andreas Tille <tille@debian.org>
Subject: Re: Bug#685787: Praat has serious bug #713597
Date: Sat, 02 Nov 2013 13:08:12 +0100
On Sa, 2013-11-02 at 12:03 +0100, Rafael Laboissiere wrote:
> * Benjamin Drung <bdrung@debian.org> [2013-11-02 00:05]:
> >
> > I have just one recommendation/wish: It would be nice if test cases 
> > could be added for the new feature. The test cases should work offline.
> 
> Would something along the lines of the very simple-minded shell script 
> attached below be appropriate?  Of course, it will need adaptation for 
> the shunit2 framework used in devscripts.

Yes, that's exactly what I hoped for. We already have test/test_uscan,
which contains one online test. This could be converted to an offline
test with your test framework.

> What this script does is (1) create a minimal Debian package directory, 
> containing minimal files debian/{changelog,watch,copyright}, (2) create a 
> minimal repository, containing a tarball (built on the fly), and (3) 
> start an HTTP server that works offline, using the SimpleHTTPServer 
> module of Python.

Maybe this short description could be added to the test case as comment
(for documentation).

-- 
Benjamin Drung
Debian & Ubuntu Developer




Information forwarded to debian-bugs-dist@lists.debian.org, Devscripts Devel Team <devscripts-devel@lists.alioth.debian.org>:
Bug#685787; Package devscripts. (Sat, 02 Nov 2013 17:45:05 GMT) Full text and rfc822 format available.

Acknowledgement sent to Rafael Laboissiere <rafael@laboissiere.net>:
Extra info received and forwarded to list. Copy sent to Devscripts Devel Team <devscripts-devel@lists.alioth.debian.org>. (Sat, 02 Nov 2013 17:45:05 GMT) Full text and rfc822 format available.

Message #117 received at 685787@bugs.debian.org (full text, mbox):

From: Rafael Laboissiere <rafael@laboissiere.net>
To: Benjamin Drung <bdrung@debian.org>
Cc: 685787@bugs.debian.org, Andreas Tille <tille@debian.org>
Subject: Re: Bug#685787: Praat has serious bug #713597
Date: Sat, 2 Nov 2013 18:40:08 +0100
[Message part 1 (text/plain, inline)]
* Benjamin Drung <bdrung@debian.org> [2013-11-02 13:08]:

> On Sa, 2013-11-02 at 12:03 +0100, Rafael Laboissiere wrote:
>> * Benjamin Drung <bdrung@debian.org> [2013-11-02 00:05]:
>>>
>>> I have just one recommendation/wish: It would be nice if test cases 
>>> could be added for the new feature. The test cases should work offline.
>>
>> Would something along the lines of the very simple-minded shell script 
>> attached below be appropriate?  Of course, it will need adaptation for 
>> the shunit2 framework used in devscripts.
>
> Yes, that's exactly what I hoped for. We already have test/test_uscan, 
> which contains one online test. This could be converted to an offline 
> test with your test framework.
>
>> What this script does is (1) create a minimal Debian package directory, 
>> containing minimal files debian/{changelog,watch,copyright}, (2) create a 
>> minimal repository, containing a tarball (built on the fly), and (3) 
>> start an HTTP server that works offline, using the SimpleHTTPServer 
>> module of Python.
>
> Maybe this short description could be added to the test case as comment 
> (for documentation).

Ok, I did it and also changed test/Makefile accordingly. The patch is 
attached below.  Note that I also added an entry in debian/copyright, but 
that may be wrong.  There is no need to build-depend on libpython-stdlib 
(for the SimpleHTTPServer module), because python3-all pulls it in. This 
patch works here inside my pbuilder.

Cheers,

Rafael Laboissière

[0001-Add-test-for-the-file-exclusion-feature-of-uscan.patch (text/x-diff, attachment)]

Information forwarded to debian-bugs-dist@lists.debian.org, Devscripts Devel Team <devscripts-devel@lists.alioth.debian.org>:
Bug#685787; Package devscripts. (Sat, 02 Nov 2013 23:27:05 GMT) Full text and rfc822 format available.

Acknowledgement sent to Benjamin Drung <bdrung@debian.org>:
Extra info received and forwarded to list. Copy sent to Devscripts Devel Team <devscripts-devel@lists.alioth.debian.org>. (Sat, 02 Nov 2013 23:27:05 GMT) Full text and rfc822 format available.

Message #122 received at 685787@bugs.debian.org (full text, mbox):

From: Benjamin Drung <bdrung@debian.org>
To: Rafael Laboissiere <rafael@laboissiere.net>
Cc: 685787@bugs.debian.org, Andreas Tille <tille@debian.org>
Subject: Re: Bug#685787: Praat has serious bug #713597
Date: Sun, 03 Nov 2013 00:24:02 +0100
On Sa, 2013-11-02 at 18:40 +0100, Rafael Laboissiere wrote:
> * Benjamin Drung <bdrung@debian.org> [2013-11-02 13:08]:
> 
> > On Sa, 2013-11-02 at 12:03 +0100, Rafael Laboissiere wrote:
> >> * Benjamin Drung <bdrung@debian.org> [2013-11-02 00:05]:
> >>>
> >>> I have just one recommendation/wish: It would be nice if test cases 
> >>> could be added for the new feature. The test cases should work offline.
> >>
> >> Would something along the lines of the very simple-minded shell script 
> >> attached below be appropriate?  Of course, it will need adaptation for 
> >> the shunit2 framework used in devscripts.
> >
> > Yes, that's exactly what I hoped for. We already have test/test_uscan, 
> > which contains one online test. This could be converted to an offline 
> > test with your test framework.
> >
> >> What this script does is (1) create a minimal Debian package directory, 
> >> containing minimal files debian/{changelog,watch,copyright}, (2) create a 
> >> minimal repository, containing a tarball (built on the fly), and (3) 
> >> start an HTTP server that works offline, using the SimpleHTTPServer 
> >> module of Python.
> >
> > Maybe this short description could be added to the test case as comment 
> > (for documentation).
> 
> Ok, I did it and also changed test/Makefile accordingly. The patch is 
> attached below.  Note that I also added an entry in debian/copyright, but 
> that may be wrong.  There is no need to build-depend on libpython-stdlib 
> (for the SimpleHTTPServer module), because python3-all pulls it in. This 
> patch works here inside my pbuilder.

The modification on debian/copyright is okay. I have some comments:

1) I like to have one test file for each script which contains one or
more tests. So the test file for uscan should be called test_uscan and
contain a test function testFileExclusion using shunit.

2) The test in test_uscan should be converted to an offline test or
test_uscan should be renamed to test_uscan_online.

3) The test could do more validity checks. It could compare the list of
files in the tarball with the expected content.

-- 
Benjamin Drung
Debian & Ubuntu Developer




Information forwarded to debian-bugs-dist@lists.debian.org, Devscripts Devel Team <devscripts-devel@lists.alioth.debian.org>:
Bug#685787; Package devscripts. (Sun, 03 Nov 2013 15:15:05 GMT) Full text and rfc822 format available.

Acknowledgement sent to Rafael Laboissiere <rafael@laboissiere.net>:
Extra info received and forwarded to list. Copy sent to Devscripts Devel Team <devscripts-devel@lists.alioth.debian.org>. (Sun, 03 Nov 2013 15:15:05 GMT) Full text and rfc822 format available.

Message #127 received at 685787@bugs.debian.org (full text, mbox):

From: Rafael Laboissiere <rafael@laboissiere.net>
To: Benjamin Drung <bdrung@debian.org>
Cc: 685787@bugs.debian.org, Andreas Tille <tille@debian.org>
Subject: Re: Bug#685787: Praat has serious bug #713597
Date: Sun, 3 Nov 2013 16:10:19 +0100
[Message part 1 (text/plain, inline)]
* Benjamin Drung <bdrung@debian.org> [2013-11-03 00:24]:
>
> The modification on debian/copyright is okay. I have some comments:
>
> 1) I like to have one test file for each script which contains one or 
> more tests. So the test file for uscan should be called test_uscan and 
> contain a test function testFileExclusion using shunit.
>
> 2) The test in test_uscan should be converted to an offline test or 
> test_uscan should be renamed to test_uscan_online.
>
> 3) The test could do more validity checks. It could compare the list of 
> files in the tarball with the expected content.

Attached below is the patch implementing the above requests.  It renames 
test_uscan to test_uscan_online and includes the shunit2 test function 
testFileExclusion in test_uscan.  Two tests are included: first, it 
checks whether the "online download" of the tarball succeeded and, 
second, it checks whether the intended file was really excluded.

Here is the relevant part of the build log of the package:

   ./test_uscan
   testFileExclusion
   127.0.0.1 - - [03/Nov/2013 12:07:13] "GET / HTTP/1.1" 200 -
   127.0.0.1 - - [03/Nov/2013 12:07:13] "GET /foo-1.tar.gz HTTP/1.1" 200 -
   foo: Newer version (1) available on remote site:
     http://localhost:8000/foo-1.tar.gz
     (local version is 0)
   foo: Successfully downloaded updated package foo-1.tar.gz
       and removed files from it in foo_1+dfsg.orig.tar.gz

   Ran 1 test.

   OK


Rafael

[0001-Add-test-for-the-file-exclusion-feature-of-uscan.patch (text/x-diff, attachment)]

Added tag(s) pending. Request was from James McCoy <jamessan@debian.org> to control@bugs.debian.org. (Wed, 20 Nov 2013 05:45:05 GMT) Full text and rfc822 format available.

Message sent on to Andreas Tille <tille@debian.org>:
Bug#685787. (Thu, 21 Nov 2013 03:57:21 GMT) Full text and rfc822 format available.

Message #132 received at 685787-submitter@bugs.debian.org (full text, mbox):

From: James McCoy <jamessan@debian.org>
To: 685787-submitter@bugs.debian.org
Subject: Bug#685787 marked as pending
Date: Thu, 21 Nov 2013 03:53:50 +0000
tag 685787 pending
thanks

Hello,

Bug #685787 reported by you has been fixed in the Git repository. You can
see the changelog below, and you can check the diff of the fix at:

    http://git.debian.org/?p=collab-maint/devscripts.git;a=commitdiff;h=3e02bb9

---
commit 3e02bb91f06a369657f29d5e4d4034ae2444288f
Author: James McCoy <jamessan@debian.org>
Date:   Tue Nov 19 22:32:07 2013 -0500

    Document uscan repack functionality in debian/changelog
    
    Signed-off-by: James McCoy <jamessan@debian.org>

diff --git a/debian/changelog b/debian/changelog
index 43288f9..b2c1faa 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -3,6 +3,10 @@ devscripts (2.13.5) UNRELEASED; urgency=low
   [ James McCoy ]
   * namecheck: Fix “406 Not Acceptable” error when querying Alioth.  (Closes:
     #725228)
+  * uscan: Allow specifying file exclusion rules in d/copyright so uscan can
+    automatically repack upstream archives which contain non-DFSG content.
+    Thanks to Andreas Tille, gregor herrmann, and Rafael Laboissiere for the
+    patches.  (Closes: #685787)
 
   [ Evgeni Golov ]
   * debcheckout: allow setting the user for auth mode in the config.  (Closes:



Marked as found in versions devscripts/2.11.8. Request was from James McCoy <jamessan@debian.org> to 677270-submit@bugs.debian.org. (Wed, 04 Dec 2013 05:03:06 GMT) Full text and rfc822 format available.

Merged 677270 685787 Request was from James McCoy <jamessan@debian.org> to 677270-submit@bugs.debian.org. (Wed, 04 Dec 2013 05:03:07 GMT) Full text and rfc822 format available.

Reply sent to James McCoy <jamessan@debian.org>:
You have taken responsibility. (Thu, 05 Dec 2013 03:51:16 GMT) Full text and rfc822 format available.

Notification sent to Andreas Tille <tille@debian.org>:
Bug acknowledged by developer. (Thu, 05 Dec 2013 03:51:16 GMT) Full text and rfc822 format available.

Message #141 received at 685787-close@bugs.debian.org (full text, mbox):

From: James McCoy <jamessan@debian.org>
To: 685787-close@bugs.debian.org
Subject: Bug#685787: fixed in devscripts 2.13.5
Date: Thu, 05 Dec 2013 03:49:11 +0000
Source: devscripts
Source-Version: 2.13.5

We believe that the bug you reported is fixed in the latest version of
devscripts, which is due to be installed in the Debian FTP archive.

A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to 685787@bugs.debian.org,
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
James McCoy <jamessan@debian.org> (supplier of updated devscripts package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing ftpmaster@ftp-master.debian.org)


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA512

Format: 1.8
Date: Wed, 04 Dec 2013 22:27:45 -0500
Source: devscripts
Binary: devscripts
Architecture: source amd64
Version: 2.13.5
Distribution: unstable
Urgency: low
Maintainer: Devscripts Devel Team <devscripts-devel@lists.alioth.debian.org>
Changed-By: James McCoy <jamessan@debian.org>
Description: 
 devscripts - scripts to make the life of a Debian Package maintainer easier
Closes: 624317 674579 685787 722171 725228 726694 728177 729779 730343
Changes: 
 devscripts (2.13.5) unstable; urgency=low
 .
   [ James McCoy ]
   * namecheck: Fix “406 Not Acceptable” error when querying Alioth.  (Closes:
     #725228)
   * uscan:
     + Allow specifying file exclusion rules in d/copyright so uscan can
       automatically repack upstream archives which contain non-DFSG content.
       Thanks to Andreas Tille, gregor herrmann, and Rafael Laboissiere for the
       patches.  (Closes: #685787)
     + Require LWP::Protocol::https instead of Crypt::SSLeay to access https
       sites.  (Closes: #624317)
   * test/*:
     + Pass --no-conf to commands which may be influenced by ~/.devscripts
     + Fix a test failure in test_uscan_online due to different version format.
   * rc-alert: Be more flexible in the formatting of the HTML being parsed.
     (Closes: #729779)
   * who-uploads: Use long keyid format to avoid ambiguity.  (Closes: #674579)
 .
   [ Evgeni Golov ]
   * debcheckout: allow setting the user for auth mode in the config.  (Closes:
     #722171)
 .
   [ Joachim Breitner ]
   * debcommit: Fix --release with darcs when the repository is clean. (Closes:
     #728177)
 .
   [ Christoph Berg ]
   * origtargz: Document pristine-tar support in the manpage.
   * rmadison: Support -r (--regex) parameter. (This is still unsupported on
     qa.debian.org, but possible on some 3rd-party repositories like
     apt.postgresql.org.)
 .
   [ Benjamin Drung ]
   * test/test_debchange: Strip distribution data outdated warnings. (Closes:
     #726694)
 .
   [ Translation updates ]
   * German, Chris Leick.
   * French, David Prévot.
 .
   [ Julien Cristau ]
   * debchange: the default setting for urgency is now 'medium' (Closes: #730343)
Checksums-Sha1: 
 9d3caba264d015b13563470dbc07b26f355fad77 2123 devscripts_2.13.5.dsc
 fbcbba5ae6bd9131119137fa822b971944e01b39 577348 devscripts_2.13.5.tar.xz
 6d28905a19bb9856e00969974515f472daebe096 861704 devscripts_2.13.5_amd64.deb
Checksums-Sha256: 
 8ea412345d45bb6344b277248ae6d3a60940dfa3bdad01f6beacfe8488aacafc 2123 devscripts_2.13.5.dsc
 ffa8b04c594f507907734181a7fc76ccd54b0844e5c37b1a7fc83184d75f2c28 577348 devscripts_2.13.5.tar.xz
 a6f41037e8b5ed763a9b2440713174b665bb372e30a2f15a4f51a32e300794cd 861704 devscripts_2.13.5_amd64.deb
Files: 
 734d0b06b7e1f491f53acdf77f4172c8 2123 devel optional devscripts_2.13.5.dsc
 514c82986d261883ce43ea54936d4a51 577348 devel optional devscripts_2.13.5.tar.xz
 17780b2037ff9c05f2f94d1565a09953 861704 devel optional devscripts_2.13.5_amd64.deb

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.15 (GNU/Linux)

iQIcBAEBCgAGBQJSn/WGAAoJEN/mka4zG6PbO5gP/0X7yYW+oCPaSnsHcJhruED7
cB59l885eSW0u1z7YPWGBXYuPrSaqwDG3DFmhd52tUicJqA2UQ/Rm1QOm9i0zWep
Rr0XVsmKCL+cxB9SmMID1zGCFKjmCgzApmY1WlrdXp/pe21FeRDyY4n7CnGlpno7
6M+YjoE7uow+ydncH1Zz8wH9YRAODSvxTejk3SNSZnkDvEKfkrd9pBaYvdlY/1hY
R3Pujezx4D0ssKDVMKfduyH4XBi5vdXhc4l6l9mczNd0sVZj+T2Crm/rnBAJiJE0
aOV1aspAPIx1O2E/EU6SKymNG6h8HKqmcsA0G+Hyv7ggT4GROpGHvkDiRDPDclMy
TtPCVuLbTbTAlHvJAQPsGlWS8EK1mnEP5YNfQj/XS028PuG8oVFAPYeSrWdbU4nh
24DE4aJZh01q02jOW7nZ7Wa63xV2JbpoTRKIQiK2wYh39XRJvKxKy9vHuSre6ocC
YqHTg3mTk2SSYy2MIxMdpk/adHcpu/6S5+uVJJmKZxJcqj9HRv2Q2iCqJB8pXX6C
bX6RJC+NX4bqjqxyGc+np0YJ7tLEccuRbCx52u6pHS7AYCkePLWK/2s8NRXkcBK5
nCbZiCBm0MmgOcI7WhkpIiPl9yc2N/AcoBBZNTKROC+GivyHnyV9Az0mTjvw17bu
udKYQwn+y/w7F4lrPMfF
=xi80
-----END PGP SIGNATURE-----




Reply sent to James McCoy <jamessan@debian.org>:
You have taken responsibility. (Thu, 05 Dec 2013 03:51:17 GMT) Full text and rfc822 format available.

Notification sent to Nicholas Bamber <nicholas@periapt.co.uk>:
Bug acknowledged by developer. (Thu, 05 Dec 2013 03:51:17 GMT) Full text and rfc822 format available.

Bug archived. Request was from Debbugs Internal Request <owner@bugs.debian.org> to internal_control@bugs.debian.org. (Tue, 07 Jan 2014 07:32:40 GMT) Full text and rfc822 format available.

Send a report that this bug log contains spam.


Debian bug tracking system administrator <owner@bugs.debian.org>. Last modified: Thu Apr 17 19:50:39 2014; Machine Name: buxtehude.debian.org

Debian Bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.