Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make refs support submodules #145

Closed
wants to merge 1 commit into from

Conversation

ekohl
Copy link

@ekohl ekohl commented Oct 7, 2012

In a submodule the git_dir is actually a file which contains the location of the actual git dir in the format gitdir: my/actual/dir.

I've already verified manually that it solves my issue (aanand/git-up#31) but I'm quite new to ruby and grit so I could use some advice on how to write the unit tests.

In a submodule the git_dir is actually a file which contains the
location of the actual git dir in the format gitdir: my/actual/dir.
@ekohl
Copy link
Author

ekohl commented Oct 8, 2012

According to git-commit-id/git-commit-id-maven-plugin#19 (comment) this changed in 1.7.8. From https://lkml.org/lkml/2011/12/2/316:

  • When populating a new submodule directory with "git submodule init",
    the $GIT_DIR metainformation directory for submodules is created inside
    $GIT_DIR/modules// directory of the superproject and referenced
    via the gitfile mechanism. This is to make it possible to switch
    between commits in the superproject that has and does not have the
    submodule in the tree without re-cloning.

@jakearchibald
Copy link

Would love to see this rolled in

@jfirebaugh
Copy link

👍 I ran into this problem trying to use git up within a submodule. See aanand/git-up#24 and aanand/git-up#31.

@vad4msiu
Copy link

+1

@bkeepers
Copy link
Collaborator

bkeepers commented Feb 3, 2014

Grit is no longer maintained. See #183 and check out libgit2/rugged.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants