Visitar URL original
Problems under cygwin with out of tree repository · Issue #31 · msiemens/PyGitUp · GitHub
Skip to content

Problems under cygwin with out of tree repository #31

Closed

Description

@RedX2501

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

Activity

  1. msiemens commented on Jul 15, 2015

    @msiemens
    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?

  2. RedX2501 commented on Jul 15, 2015

    @RedX2501
    Author

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

    2015-07-15_18-44-57

  3. msiemens commented on Jul 15, 2015

    @msiemens
    Owner

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

  4. RedX2501 commented on Jul 15, 2015

    @RedX2501
    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

  5. msiemens commented on Aug 18, 2015

    @msiemens
    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?

  6. msiemens commented on Feb 22, 2016

    @msiemens
    Owner

    @RedX2501 Is this still relevant?

  7. RedX2501 commented on Mar 7, 2016

    @RedX2501
    Author

    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.

  8. msiemens commented on Mar 7, 2016

    @msiemens
    Owner

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

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

  9. RedX2501 commented on Mar 7, 2016

    @RedX2501
    Author

    Yes

  10. msiemens commented on Mar 7, 2016

    @msiemens
    Owner

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

  11. msiemens commented on Nov 3, 2016

    @msiemens
    Owner

    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?

  12. msiemens commented on Aug 30, 2017

    @msiemens
    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

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions