You are viewing a plain text version of this content. The canonical link for it is here.
Posted to infrastructure-issues@apache.org by "Daniel Truemper (JIRA)" <ji...@apache.org> on 2010/05/25 15:23:28 UTC

[jira] Created: (INFRA-2739) Tags don't show up in git

Tags don't show up in git
-------------------------

                 Key: INFRA-2739
                 URL: https://issues.apache.org/jira/browse/INFRA-2739
             Project: Infrastructure
          Issue Type: Bug
      Security Level: public (Regular issues)
          Components: Git
            Reporter: Daniel Truemper


Hi,

somehow the SVN tags are not visible from Git. Instead of showing up as a tag each tag is listed as "tags/$TAG" branch.

Usually with

$ git svn clone -s  http://svn.apache.org/repos/asf/couchdb/

all branches and tags should show up correctly! It may be possible that with older versions of Git you explicitly need to set the "{trunk,tags,branches}" names:

$ git svn clone --trunk=trunk --branches=branches --tags=tags http://svn.apache.org/repos/asf/couchdb/

HTH
Daniel

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Closed: (INFRA-2739) Tags don't show up in git

Posted by "Daniel Truemper (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/INFRA-2739?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Daniel Truemper closed INFRA-2739.
----------------------------------


Hi Jukka,

thanks! Looks good as far as my small survey showed! Thanks!

Best, Daniel

> Tags don't show up in git
> -------------------------
>
>                 Key: INFRA-2739
>                 URL: https://issues.apache.org/jira/browse/INFRA-2739
>             Project: Infrastructure
>          Issue Type: Bug
>      Security Level: public(Regular issues) 
>          Components: Git
>            Reporter: Daniel Truemper
>            Assignee: Jukka Zitting
>         Attachments: git-tags.patch
>
>
> Hi,
> somehow the SVN tags are not visible from Git. Instead of showing up as a tag each tag is listed as "tags/$TAG" branch.
> Usually with
> $ git svn clone -s  http://svn.apache.org/repos/asf/couchdb/
> all branches and tags should show up correctly! It may be possible that with older versions of Git you explicitly need to set the "{trunk,tags,branches}" names:
> $ git svn clone --trunk=trunk --branches=branches --tags=tags http://svn.apache.org/repos/asf/couchdb/
> HTH
> Daniel

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (INFRA-2739) Tags don't show up in git

Posted by "Daniel Truemper (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/INFRA-2739?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12871216#action_12871216 ] 

Daniel Truemper commented on INFRA-2739:
----------------------------------------

Ups, you are right! git-svn is not doing this automatically. Instead I used the following call (on OS X):

$ git for-each-ref refs/remotes/tags | cut -d / -f 4- | while read ref; do git tag -a "$ref" -m"tag for $ref" "refs/remotes/tags/$ref"; done

May be it would be possible to integrate this as a post-commit-hook?

Best
Daniel

> Tags don't show up in git
> -------------------------
>
>                 Key: INFRA-2739
>                 URL: https://issues.apache.org/jira/browse/INFRA-2739
>             Project: Infrastructure
>          Issue Type: Bug
>      Security Level: public(Regular issues) 
>          Components: Git
>            Reporter: Daniel Truemper
>            Assignee: Jukka Zitting
>
> Hi,
> somehow the SVN tags are not visible from Git. Instead of showing up as a tag each tag is listed as "tags/$TAG" branch.
> Usually with
> $ git svn clone -s  http://svn.apache.org/repos/asf/couchdb/
> all branches and tags should show up correctly! It may be possible that with older versions of Git you explicitly need to set the "{trunk,tags,branches}" names:
> $ git svn clone --trunk=trunk --branches=branches --tags=tags http://svn.apache.org/repos/asf/couchdb/
> HTH
> Daniel

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (INFRA-2739) Tags don't show up in git

Posted by "Daniel Truemper (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/INFRA-2739?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12871197#action_12871197 ] 

Daniel Truemper commented on INFRA-2739:
----------------------------------------

Well, yes and no.

Yes, svn tags are just special branches. And no, git-svn does find out at which commit the svn tag branch has been created and then adds a git-tag.

See for example:

http://code.google.com/p/jcouchdb/source/browse/#svn/tags

and my github mirror for that project:

http://github.com/truemped/jcouchdb

where the tags do show up!

> Tags don't show up in git
> -------------------------
>
>                 Key: INFRA-2739
>                 URL: https://issues.apache.org/jira/browse/INFRA-2739
>             Project: Infrastructure
>          Issue Type: Bug
>      Security Level: public(Regular issues) 
>          Components: Git
>            Reporter: Daniel Truemper
>            Assignee: Jukka Zitting
>
> Hi,
> somehow the SVN tags are not visible from Git. Instead of showing up as a tag each tag is listed as "tags/$TAG" branch.
> Usually with
> $ git svn clone -s  http://svn.apache.org/repos/asf/couchdb/
> all branches and tags should show up correctly! It may be possible that with older versions of Git you explicitly need to set the "{trunk,tags,branches}" names:
> $ git svn clone --trunk=trunk --branches=branches --tags=tags http://svn.apache.org/repos/asf/couchdb/
> HTH
> Daniel

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (INFRA-2739) Tags don't show up in git

Posted by "Jukka Zitting (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/INFRA-2739?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12901994#action_12901994 ] 

Jukka Zitting commented on INFRA-2739:
--------------------------------------

Thanks! I committed a somewhat modified version of the patch in revision 776318.

The updated script no longer makes new tags available as "tags/$tagname" pseudo-branches, but old such pseudo-branches still remain to avoid confusion for existing clones. If people prefer, we can also remove such extra branches.

The updated script will automatically update (or remove) the Git tags based on changes in the upstream codebase in Subversion. Such changes will *not* be automatically reflected in downstream Git clones. See the "On Re-tagging" section in http://www.kernel.org/pub/software/scm/git/docs/git-tag.html for more details on how to handle such cases.

> Tags don't show up in git
> -------------------------
>
>                 Key: INFRA-2739
>                 URL: https://issues.apache.org/jira/browse/INFRA-2739
>             Project: Infrastructure
>          Issue Type: Bug
>      Security Level: public(Regular issues) 
>          Components: Git
>            Reporter: Daniel Truemper
>            Assignee: Jukka Zitting
>         Attachments: git-tags.patch
>
>
> Hi,
> somehow the SVN tags are not visible from Git. Instead of showing up as a tag each tag is listed as "tags/$TAG" branch.
> Usually with
> $ git svn clone -s  http://svn.apache.org/repos/asf/couchdb/
> all branches and tags should show up correctly! It may be possible that with older versions of Git you explicitly need to set the "{trunk,tags,branches}" names:
> $ git svn clone --trunk=trunk --branches=branches --tags=tags http://svn.apache.org/repos/asf/couchdb/
> HTH
> Daniel

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (INFRA-2739) Tags don't show up in git

Posted by "Jukka Zitting (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/INFRA-2739?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12886673#action_12886673 ] 

Jukka Zitting commented on INFRA-2739:
--------------------------------------

I'll try with a test mirror on how a switch to real Git tags would affect downstream clones.

We could introduce this as an optional feature that can be enabled on a case by case basis on existing mirrors. If it works great, we could even make it the default for new mirrors.

BTW, if anyone wants to help out in implementing this, a patch to integrate Daniel's one-liner with [1] would be welcome!

[1] https://svn.apache.org/repos/infra/infrastructure/trunk/projects/git/

> Tags don't show up in git
> -------------------------
>
>                 Key: INFRA-2739
>                 URL: https://issues.apache.org/jira/browse/INFRA-2739
>             Project: Infrastructure
>          Issue Type: Bug
>      Security Level: public(Regular issues) 
>          Components: Git
>            Reporter: Daniel Truemper
>            Assignee: Jukka Zitting
>
> Hi,
> somehow the SVN tags are not visible from Git. Instead of showing up as a tag each tag is listed as "tags/$TAG" branch.
> Usually with
> $ git svn clone -s  http://svn.apache.org/repos/asf/couchdb/
> all branches and tags should show up correctly! It may be possible that with older versions of Git you explicitly need to set the "{trunk,tags,branches}" names:
> $ git svn clone --trunk=trunk --branches=branches --tags=tags http://svn.apache.org/repos/asf/couchdb/
> HTH
> Daniel

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Reopened: (INFRA-2739) Tags don't show up in git

Posted by "Jukka Zitting (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/INFRA-2739?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jukka Zitting reopened INFRA-2739:
----------------------------------


> git for-each-ref refs/remotes/tags | cut -d / -f 4- | while read ref; do git tag -a "$ref" -m"tag for $ref" "refs/remotes/tags/$ref"; done 

Yes, we could do something like that. But before doing so, we need to answer the following questions:

1) What happens (/ should happen) when someone commits to a tag in svn?

2) Can we switch existing mirrors to use this mechanism? Will this confuse existing clones?

Reopening until we figure out how to proceed.

> Tags don't show up in git
> -------------------------
>
>                 Key: INFRA-2739
>                 URL: https://issues.apache.org/jira/browse/INFRA-2739
>             Project: Infrastructure
>          Issue Type: Bug
>      Security Level: public(Regular issues) 
>          Components: Git
>            Reporter: Daniel Truemper
>            Assignee: Jukka Zitting
>
> Hi,
> somehow the SVN tags are not visible from Git. Instead of showing up as a tag each tag is listed as "tags/$TAG" branch.
> Usually with
> $ git svn clone -s  http://svn.apache.org/repos/asf/couchdb/
> all branches and tags should show up correctly! It may be possible that with older versions of Git you explicitly need to set the "{trunk,tags,branches}" names:
> $ git svn clone --trunk=trunk --branches=branches --tags=tags http://svn.apache.org/repos/asf/couchdb/
> HTH
> Daniel

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Resolved: (INFRA-2739) Tags don't show up in git

Posted by "Jukka Zitting (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/INFRA-2739?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jukka Zitting resolved INFRA-2739.
----------------------------------

    Resolution: Fixed

After some experimentation I figured that removing the old pseudo-branches won't harm existing clones, so I went ahead and removed them from all the mirrors.

That should cover everything for this issue, so I'm resolving this as fixed.

> Tags don't show up in git
> -------------------------
>
>                 Key: INFRA-2739
>                 URL: https://issues.apache.org/jira/browse/INFRA-2739
>             Project: Infrastructure
>          Issue Type: Bug
>      Security Level: public(Regular issues) 
>          Components: Git
>            Reporter: Daniel Truemper
>            Assignee: Jukka Zitting
>         Attachments: git-tags.patch
>
>
> Hi,
> somehow the SVN tags are not visible from Git. Instead of showing up as a tag each tag is listed as "tags/$TAG" branch.
> Usually with
> $ git svn clone -s  http://svn.apache.org/repos/asf/couchdb/
> all branches and tags should show up correctly! It may be possible that with older versions of Git you explicitly need to set the "{trunk,tags,branches}" names:
> $ git svn clone --trunk=trunk --branches=branches --tags=tags http://svn.apache.org/repos/asf/couchdb/
> HTH
> Daniel

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Resolved: (INFRA-2739) Tags don't show up in git

Posted by "Jukka Zitting (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/INFRA-2739?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jukka Zitting resolved INFRA-2739.
----------------------------------

      Assignee: Jukka Zitting
    Resolution: Not A Problem

That's the way git-svn works. The tags in Subversion are essentially just a special case of branches, as the only mechanism that prevents them from being modified is a social contract. Thus, instead of mapping Subversion tags to Git tags, git-svn turns them into special "tags/" branches.

> Tags don't show up in git
> -------------------------
>
>                 Key: INFRA-2739
>                 URL: https://issues.apache.org/jira/browse/INFRA-2739
>             Project: Infrastructure
>          Issue Type: Bug
>      Security Level: public(Regular issues) 
>          Components: Git
>            Reporter: Daniel Truemper
>            Assignee: Jukka Zitting
>
> Hi,
> somehow the SVN tags are not visible from Git. Instead of showing up as a tag each tag is listed as "tags/$TAG" branch.
> Usually with
> $ git svn clone -s  http://svn.apache.org/repos/asf/couchdb/
> all branches and tags should show up correctly! It may be possible that with older versions of Git you explicitly need to set the "{trunk,tags,branches}" names:
> $ git svn clone --trunk=trunk --branches=branches --tags=tags http://svn.apache.org/repos/asf/couchdb/
> HTH
> Daniel

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (INFRA-2739) Tags don't show up in git

Posted by "Daniel Truemper (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/INFRA-2739?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Daniel Truemper updated INFRA-2739:
-----------------------------------

    Attachment: git-tags.patch

Hi Jukka,

a small patch adding the oneliner as 4 lines into update-mirror.sh but I am not sure if this is the right place.

Best
Daniel

> Tags don't show up in git
> -------------------------
>
>                 Key: INFRA-2739
>                 URL: https://issues.apache.org/jira/browse/INFRA-2739
>             Project: Infrastructure
>          Issue Type: Bug
>      Security Level: public(Regular issues) 
>          Components: Git
>            Reporter: Daniel Truemper
>            Assignee: Jukka Zitting
>         Attachments: git-tags.patch
>
>
> Hi,
> somehow the SVN tags are not visible from Git. Instead of showing up as a tag each tag is listed as "tags/$TAG" branch.
> Usually with
> $ git svn clone -s  http://svn.apache.org/repos/asf/couchdb/
> all branches and tags should show up correctly! It may be possible that with older versions of Git you explicitly need to set the "{trunk,tags,branches}" names:
> $ git svn clone --trunk=trunk --branches=branches --tags=tags http://svn.apache.org/repos/asf/couchdb/
> HTH
> Daniel

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (INFRA-2739) Tags don't show up in git

Posted by "Owen O'Malley (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/INFRA-2739?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12876934#action_12876934 ] 

Owen O'Malley commented on INFRA-2739:
--------------------------------------

Personally, I think it would be great to get the tags as tags.
  1. If someone moves the tag in svn, probably moving the tag in git is probably right. Note that in git, the users that have already seen the old tag won't get the new one.
  2. I don't know if it would confuse the down stream clones, but I would be surprised.

-- Owen

> Tags don't show up in git
> -------------------------
>
>                 Key: INFRA-2739
>                 URL: https://issues.apache.org/jira/browse/INFRA-2739
>             Project: Infrastructure
>          Issue Type: Bug
>      Security Level: public(Regular issues) 
>          Components: Git
>            Reporter: Daniel Truemper
>            Assignee: Jukka Zitting
>
> Hi,
> somehow the SVN tags are not visible from Git. Instead of showing up as a tag each tag is listed as "tags/$TAG" branch.
> Usually with
> $ git svn clone -s  http://svn.apache.org/repos/asf/couchdb/
> all branches and tags should show up correctly! It may be possible that with older versions of Git you explicitly need to set the "{trunk,tags,branches}" names:
> $ git svn clone --trunk=trunk --branches=branches --tags=tags http://svn.apache.org/repos/asf/couchdb/
> HTH
> Daniel

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (INFRA-2739) Tags don't show up in git

Posted by "Jukka Zitting (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/INFRA-2739?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12871204#action_12871204 ] 

Jukka Zitting commented on INFRA-2739:
--------------------------------------

Did you create the Github mirror with git-svn or with Github's svn import mechanism? If you used git-svn, what options you used to set up the mirror?

> Tags don't show up in git
> -------------------------
>
>                 Key: INFRA-2739
>                 URL: https://issues.apache.org/jira/browse/INFRA-2739
>             Project: Infrastructure
>          Issue Type: Bug
>      Security Level: public(Regular issues) 
>          Components: Git
>            Reporter: Daniel Truemper
>            Assignee: Jukka Zitting
>
> Hi,
> somehow the SVN tags are not visible from Git. Instead of showing up as a tag each tag is listed as "tags/$TAG" branch.
> Usually with
> $ git svn clone -s  http://svn.apache.org/repos/asf/couchdb/
> all branches and tags should show up correctly! It may be possible that with older versions of Git you explicitly need to set the "{trunk,tags,branches}" names:
> $ git svn clone --trunk=trunk --branches=branches --tags=tags http://svn.apache.org/repos/asf/couchdb/
> HTH
> Daniel

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.