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

Re: uscan: git repo without releases/tags



Hi Felix,

Le 03/10/2019 à 16:12, Felix Natter a écrit :

> How can I deal with this? Shall I write a debian/rules target
> 'get-orig-source' that clones the repo and creates a .tar.gz
> from that (duplicating the Files-Excluded: mechanism)?

I frequently have to deal with such tagless repositories and I have two
strategies:

1. You can clone the repository on GitHub, tag the clone and temporarily
set debian/watch to download from the clone just for running uscan and
building the upstream tarball. The downside is that the package tracker
page will appear as if the debian/watch URL is broken.

2. Another trick is to use an archive URL in debian/watch based on the
commit hash you want to package and mangle the version. The file looks
like this:

  version=4
  opts="uversionmangle=s/d993b8/0.0+20170615/" \
  https://github.com/bulenkov/iconloader/archive/(d993b8).tar.gz

Of course this won't track the new releases but at least you can run uscan.


> Is the upstream version 0.0+20191003 ok?

Sounds good. Some packages also append the commit hash (for example
0.0~20170615+gitd993b8), that's useful to disambiguate the commit if
there is more than one per day, but that's not the case for iconloader.

Emmanuel Bourg


Reply to: