[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Enabling uscan to simply remove files from upstream source

Andreas Tille <andreas@an3as.eu> writes:

> Files-Excluded:
>   docs/source/fonts/*
>   docs/source/javascripts/jquery-1.7.1.min.js
>   docs/source/javascripts/modernizr-2.5.3.min.js
> Regarding the implementation there was some uncertainity about the
> actual Perl module to use.  In the attached example 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.  The
> code works for me however, there might be some remaining empty
> directories which I'm tempted to delete these as well via an "educated"
>    find tmp -type d -empty -delete
> which means I would care for deleting only those directories that became
> empty by the previous removal process and not those directories which
> were originally empty in the tarball.  On the other hand we might simply
> go with those empty dirs that finally do not harm.
> Any further hints / remarks?

How about resolving the empty directory problem by permitting the
Files-Excluded to match directories?  Thus, if you want to remove the
docs/source/fonts/ hierarchy, you would instead write:


I'm worried that empty directories may be present for other reasons, and
removing all of them would have bad side-effects.  I would prefer to not
remove empty directories over using the find-approach above, if my
proposal is not adopted.

Thanks for doing this, I believe that having an easy way to remove files
from upstream packages will save Debian package maintainers time and


Reply to: