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

Problems under cygwin with out of tree repository #31

Closed
RedX2501 opened this issue Jul 14, 2015 · 12 comments
Closed

Problems under cygwin with out of tree repository #31

RedX2501 opened this issue Jul 14, 2015 · 12 comments

Comments

@RedX2501
Copy link

I have a .git file with a path to my gitdir. This path is in windows format so i can use git under windows also but git-up does not seem to like or understand it when using it under cygwin: Using it in the powershell it seems to work.

2015-07-14_09-51-07

@msiemens
Copy link
Owner

Interesting. Could you post the result from running git rev-parse --show-toplevel in this directory? And could you try running PyGitUp from Windows' cmd.exe?

@msiemens msiemens added the bug label Jul 15, 2015
@RedX2501
Copy link
Author

Under cmd.exe and powershell.exe it seems to work.

2015-07-15_18-44-57

@msiemens
Copy link
Owner

Okay, what's the result of git rev-parse --show-toplevel on Cygwin, CMD and Powershell?

@RedX2501
Copy link
Author

Powershell:

D:/_P/(obscured)/SW/50_Implementation

Cygwin:

/cygdrive/d/_P/(obscured)/SW/50_Implementation

git rev-parse --git-dir yields:

Powershell:

D:/Git_repos/out_of_tree/repo_name.git

Cygwin:

/cygdrive/d/Git_repos/out_of_tree/repo_name.git

@msiemens
Copy link
Owner

Just out of curiosity, what happens, if you use /cygdrive/d/Git_repos/out_of_tree/repo_name.git in your .git file instead of D:/Git_repos/out_of_tree/repo_name.git?

@msiemens
Copy link
Owner

@RedX2501 Is this still relevant?

@RedX2501
Copy link
Author

RedX2501 commented Mar 7, 2016

Tried it out with 1.4.0 and still the same behaviour.

Traceback (most recent call last):
  File "/usr/bin/git-up", line 9, in <module>
    load_entry_point('git-up==1.4.0', 'console_scripts', 'git-up')()
  File "/usr/lib/python2.7/site-packages/PyGitUp/gitup.py", line 599, in run
    gitup = GitUp()
  File "/usr/lib/python2.7/site-packages/PyGitUp/gitup.py", line 156, in __init__
    odbt=GitCmdObjectDB)
  File "/usr/lib/python2.7/site-packages/git/repo/base.py", line 165, in __init__
    raise InvalidGitRepositoryError(epath)
git.exc.InvalidGitRepositoryError: /cygdrive/d/(...)Implementation

Output with a cygwin path produces a correct git-up error message:
Can't update your repo because it doesn't has any branches with tracking information.

@msiemens
Copy link
Owner

msiemens commented Mar 7, 2016

Output with a cygwin path produces a correct git-up error message:

You mean when using a cygwin path in the .git file?

@RedX2501
Copy link
Author

RedX2501 commented Mar 7, 2016

Yes

@msiemens
Copy link
Owner

msiemens commented Mar 7, 2016

Which console did you use? PowerShell or the Cygwin shell? If it's with both, this problem is fixed, isn't it?

@msiemens
Copy link
Owner

msiemens commented Nov 3, 2016

Just a quick heads up: GitPython v2.1.0 promises to improve Cygwin support (see this PR). It seems to improve path handling with Cygwin so maybe it fixes this problem. Could you update GitPython (pip install -U GitPython) and see if the problem is fixed?

@msiemens
Copy link
Owner

Closing due to inactivity, feel free to re-open if this is still an issue.

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

No branches or pull requests

2 participants