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

GITHUB-407: Gracefully handle Cygwin paths on Windows when determining root directory #408

Merged
merged 1 commit into from
Aug 23, 2024

Conversation

anenviousguest
Copy link

@anenviousguest anenviousguest commented May 21, 2024

Fixes #407

@anenviousguest
Copy link
Author

hi @ejoffe , any chance to get the feedback on this ? thanks.

@ejoffe
Copy link
Owner

ejoffe commented May 30, 2024

Sorry about the delay. Looks good to me.
One nit: is there a better check to see if it's cygwin instead of checking the HasPrefix equal to cygdrive? this seems fragile.

@anenviousguest
Copy link
Author

anenviousguest commented May 30, 2024

Hi @ejoffe

is there a better check to see if it's cygwin instead of checking the HasPrefix equal to cygdrive? this seems fragile.

within shell scripts, the check would typically be based on uname -a command output - but apparently this won't work if spr is running in plain CMD environment. So i didn't want to overcomplicate the implementation which i won't be able to test anyway, because my cygwin paths all start with /cygdrive

@anenviousguest
Copy link
Author

@ejoffe any chance to get this merged ? 😅

@ejoffe ejoffe merged commit d33de79 into ejoffe:master Aug 23, 2024
1 check passed
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.

Fails on windows under cygwin when determining git's root directory
2 participants