[OpenWrt-Devel] SVN to GIT transition

Jonathan Bennett jbscience87 at gmail.com
Mon Oct 12 15:21:16 EDT 2015

On Mon, Oct 12, 2015 at 2:11 PM David Lang <david at lang.hm> wrote:

> On Mon, 12 Oct 2015, Felix Fietkau wrote:
> > On 2015-10-12 16:11, Roman Yeryomin wrote:
> >> On 12 October 2015 at 16:34, Felix Fietkau <nbd at openwrt.org> wrote:
> >>> On 2015-10-12 15:09, Javier Domingo Cansino wrote:
> >>>>     Right now, the revision number (r<something>) is really useful to
> figure
> >>>>     out what particular openwrt version is being used, when people
> report
> >>>>     bugs. The commit hash cannot be used as a replacement, since it
> might be
> >>>>     one that isn't present in the official repo.
> >>>>     When using tags as a starting point (via git describe), somebody
> has to
> >>>>     create those tags, which is cumbersome (and would mean adding
> lots of
> >>>>     useless ones).
> >>>>
> >>>> The tags would be the major versions and RCs. I don't believe other
> tags
> >>>> should be used.
> >>>>
> >>>> Apart from that, I understand that if someone cloned the SVN repo
> (full
> >>>> svn history), created it's own server, and developed on top of a given
> >>>> revision X, the same problem would arise.
> >>> I haven't seen a single instance of somebody doing this, and in my
> >>> opinion it would be kind of stupid anyway :)
> >>> We don't even advertise the SVN server URL to users anymore for a
> reason.
> >>>
> >>
> >> IMO git describe --dirty would work perfectly. You would see a short
> >> hash and if user modified it or not.
> > If the user made a local commit, the short hash becomes useless.
> if the user does a SVN checkout and then modifies things, the r<number> is
> also
> not valid (although it does give you an idea where things branched)
> David Lang

His point is that users don't ever do an SVN checkout. Because the r number
is baked into the image, it's a really easy and obvious way for an end user
to report the revision in a bug report.  I can see the advantage in this.
If we are to move to git, we would want some way to preserve this feature,
that is a super easy way for a user to report the revision.  We could bake
the short hash into the image, but this would not be useful if any commits
were added locally, whereas the r number would still show some useful

Would it be possible to track the revision number in an automated way even
in a git repo?  So store the r number, and automatically increment on
commits.  Not sure if that's an option, but it seems like it might address
the problem.

--Jonathan Bennett
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.infradead.org/pipermail/openwrt-devel/attachments/20151012/f9b6c064/attachment.htm>
-------------- next part --------------
openwrt-devel mailing list
openwrt-devel at lists.openwrt.org

More information about the openwrt-devel mailing list