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

Need to set --work-tree #3

Closed
ConradIrwin opened this issue Jun 14, 2009 · 9 comments
Closed

Need to set --work-tree #3

ConradIrwin opened this issue Jun 14, 2009 · 9 comments

Comments

@ConradIrwin
Copy link

In addition to --git-dir, otherwise the current working tree will be used (if a .git directory is present, even if the --git-dir points elsewhere)

@davetron5000
Copy link
Contributor

I have a fix for this (I think; I was having this problem, too, and this fix works)

http://github.com/davetron5000/grit/tree/add-work-tree

@ghost
Copy link

ghost commented Oct 27, 2009

this is already in the smoke branch

@davetron5000
Copy link
Contributor

Yup, I think my patch was added

@ghost
Copy link

ghost commented Nov 1, 2009

it got reverted, as it broke github in some way. would be nice to get it in again

@lambda
Copy link

lambda commented Nov 15, 2010

I ran into this problem, and have fixed it in lambda/grit@2736d20; I've submitted a pull request, so hopefully that will get reviewed and applied, or sent back to me to improve and re-submit.

@vrinek
Copy link

vrinek commented Sep 14, 2012

+1

1 similar comment
@nand2
Copy link

nand2 commented Apr 6, 2013

+1

@nand2
Copy link

nand2 commented Apr 6, 2013

For info, I'm using this workaround:

mypath = '/xx/xx'
repo = Grit::Repo.new(mypath)
[..]
repo.git.reset({:env => {'GIT_WORK_TREE' => mypath}, :hard => true}, commit_id)

@bkeepers
Copy link
Collaborator

bkeepers commented Feb 3, 2014

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

@bkeepers bkeepers closed this as completed Feb 3, 2014
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

No branches or pull requests

6 participants