[devscripts] 01/01: uscan: debian/rules get-orig-source support

Osamu Aoki osamu at debian.org
Sat Dec 12 15:44:37 UTC 2015


Hi,

Maybe I should kept this in a branch for a while ...

Let me revert this until we all agree.

Non the less, let me explain my thought.

On Sat, Dec 12, 2015 at 10:27:16AM +0000, Nicholas Bamber wrote:
> James,
> 	The idea was discussed here:
> 	https://lists.alioth.debian.org/pipermail/devscripts-devel/2015-December/004496.html
> 
> 	The idea only pertained to uscan's use in informing reports like
> 	DDPO about new available versions. That said I was hoping more
> 	people, such as yourself,  would get a chance and take the time
> 	to consider the idea.

After discussing this with Nicholas, I realized any irregular repository
supports need to be done with consistent interface.  The current policy
happens to have an interesting optional target in debian/rules.

 * get-orig-source

This target fetches the most recent version of the original source
package from a canonical archive site (via FTP or WWW, for example),
does any necessary rearrangement to turn it into the original source tar
file format described below, and leaves it in the current directory.

I thought these may be used to address some bugs.
  #458789 uscan: Please allow framework for using external scripts
   -> get-orig-source target to be invoked without using internal downloader
      (This script run will not be run if --report is used to be safe.
       This is the bug, Nicholas Bamber was talking.)
  #807484 uscan: Add example for archlinux site
   -> Making version check is OK with pagemangle etc.  But adding
      get-orig-source support may be simpler for even more irregular
      site.

> On 12/12/15 00:57, James McCoy wrote:
> >On Fri, Dec 11, 2015 at 05:47:50PM +0000, Osamu Aoki wrote:
> >>commit f031c9da52c27c9c3389d00a0d7cb846bb90281d
> >>Author: Osamu Aoki <osamu at debian.org>
> >>Date:   Sat Dec 12 01:38:55 2015 +0900
> >>
> >>     uscan: debian/rules get-orig-source support
> >
> >It's fairly common for the get-orig-source target to call uscan with
> >specific options to download the version of the upstream source
> >corresponding to that package.

Yes, I see many packages have such lines:
 https://codesearch.debian.net/perpackage-results/path%3Adebian%2Frules%20uscan/2/page_0
 uscan --download-current-version --rename --force-download

This change will not conflict with such cases.  This part of code get
activated if only opts="get=get-orig-source" is used in the watch file.

Adding this kind of feature allows people to use "gbp import-orig
--uscan" to import new upstream version even if the upstream does not
fit well within mangling system.  That was my motivation.

> >I'm not quite sure I understand why uscan is being modified to support
> >calling get-orig-source.

I think such repulsive instinct is the important one and tools used by
many should not go against it just for a small gain.

So question is what is the best place to put such a script.  So far, I
have no better solution.

Another thing to think is running a custom script within "mk-origtargz
--repack" to do all sorts of clean ups for bugs such as:
 #748474 mk-origtargz: Please allow extra actions
 #807270 mk-origtargz: create reproducible tarballs and --mtime option

Osamu




More information about the devscripts-devel mailing list