<div dir="ltr">Martin and Tim,<div><br></div><div>From <a href="http://llvm.org/docs/GettingStarted.html#for-developers-to-work-with-a-git-monorepo">http://llvm.org/docs/GettingStarted.html#for-developers-to-work-with-a-git-monorepo</a></div><div><br></div><div>$ <span style="background-color:rgb(248,248,248);font-family:Consolas,"Deja Vu Sans Mono","Bitstream Vera Sans Mono",monospace;font-size:0.95em">git config --add remote.origin.fetch +refs/notes/commits:refs/notes/commits</span><br>(Its okay if you edit .git/config manually. Editing git/config is considered safe.)<br><br>FYI, I tried, in several years ago, generating refs/tags/rXXXXXX for each rev.</div><div>It works fine if number of tags are hundreds.</div><div><br></div><div>Git (and github) will be choked by thousands of tags, unfortunately.</div><div>It's the reason why I didn't provide refs/tags/rXXXXXX in github.</div><div><br></div><div>...Takumi</div><div><br><div class="gmail_quote"><div dir="ltr">On Fri, Aug 3, 2018 at 8:08 PM Tim Northover via llvm-dev <<a href="mailto:llvm-dev@lists.llvm.org">llvm-dev@lists.llvm.org</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">On Fri, 3 Aug 2018 at 11:42, Martin J. O'Riordan via llvm-dev<br>
<<a href="mailto:llvm-dev@lists.llvm.org" target="_blank">llvm-dev@lists.llvm.org</a>> wrote:<br>
> A few months ago I switched from using SVN for the LLVM project to using the GIT mono-repo, but I am still not particularly good at using GIT. How can I use the GIT command-line interface to select to the exact same set of sources used for the v7.0.0 branch,<br>
<br>
Do you mean the commit that was forked to create the 7.0 branch, the<br>
commit that was released as 7.0.0, or the current status of the 7.0<br>
branch? In turn they'd be:<br>
<br>
1. git merge-base master origin/release_70<br>
2. These are stored as tags I believe, though the format has changed<br>
and we only started recently. "git tag" lists what we have now, with<br>
an obvious mapping to releases (for a human).<br>
3. Just plain origin/release_70<br>
<br>
> or for the sources at a particular SVN revision (e.g. r338536)?<br>
<br>
For now, svn revisions are stored in notes attached to each git<br>
commit. Annoyingly they're not downloaded by default so you have to<br>
run this once:<br>
<br>
$ git fetch origin refs/notes/*:refs/notes/*<br>
<br>
After that they'll come along with every "git fetch" or "git pull".<br>
Once you have those, I personally just grep a "git log" for a revision<br>
I'm interested in. You could package some variant of<br>
<br>
$ git log --grep "git-svn-rev: 338839" -1<br>
<br>
into a script pretty easily though.<br>
<br>
Cheers.<br>
<br>
Tim.<br>
_______________________________________________<br>
LLVM Developers mailing list<br>
<a href="mailto:llvm-dev@lists.llvm.org" target="_blank">llvm-dev@lists.llvm.org</a><br>
<a href="http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev" rel="noreferrer" target="_blank">http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev</a><br>
</blockquote></div></div></div>