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

git commands not supported #9

Open
neighthan opened this issue Feb 22, 2019 · 4 comments
Open

git commands not supported #9

neighthan opened this issue Feb 22, 2019 · 4 comments

Comments

@neighthan
Copy link

Thanks for the repo! It worked fine for me with VS code, and I was inspired to write a couple of wrappers for other tools that I wanted to install on Linux and use on Windows (pdf2svg and pdflatex; my wrappers aren't terribly sophisticated, but they work for what I need).

I have come across some issues using git with your scripts such as trying to install packages from GitHub using pip; a batch file doesn't work for this, but I made an exe out of git.bat. That helped a bit (now Python can see the git command). Still, installing things gives me issues, but I haven't dug into pip's code to see what git commands are causing this. I was just wondering, do you know of specific use cases where calling git from Windows with your scripts will fail? If so, could those be listed in the README or somewhere as cases that aren't supported yet? I'll post back if I figure out what commands exactly were causing the problems I saw, but I might revert back to normal git for Windows for now.

@joaopluigi
Copy link

Hey @neighthan, @hangxingliu described this possible problem in another issue:

Because it is hard to know which part of output should be converted. For example, you mounted your drive D on /d/ in WSL. And there have /a/b/c/d/e/f/g in output of your python script. Then the converter be convert in to /a/b/c/D:\e/f/g.

Originally posted by @hangxingliu in #4 (comment)

I'm not total sure if this is related to your issue, but it looks like a very reasonable problem when working with pip. I would recommend trying to turn on the log and print the to_win_path_by_awk function result to see if you can catch that.

@hangxingliu
Copy link
Owner

@neighthan You can follow the way @joaopluigi posted.

Modify the line WSLGIT_SH_LOG=${WSLGIT_SH_LOG:-false}; in the wslgit.sh to WSLGIT_SH_LOG=true. And you can get the debug info in file wslgit.log at the same directory of wslgit.sh

@MostHated
Copy link

MostHated commented Mar 29, 2019

I don't seem to be getting a log at all and I just keep getting a permission denied error. I am trying to use SSH though, not sure if that makes a difference?

/usr/bin/wslgit.sh: line 126: /usr/bin/wslgit.log: Permission denied
/usr/bin/wslgit.sh: line 127: /usr/bin/wslgit.log: Permission denied
/usr/bin/wslgit.sh: line 128: /usr/bin/wslgit.log: Permission denied
/usr/bin/wslgit.sh: line 129: /usr/bin/wslgit.log: Permission denied
/usr/bin/wslgit.sh: line 129: /usr/bin/wslgit.log: Permission denied
/usr/bin/wslgit.sh: line 129: /usr/bin/wslgit.log: Permission denied
/usr/bin/wslgit.sh: line 177: /usr/bin/wslgit.log: Permission denied
/usr/bin/wslgit.sh: line 178: /usr/bin/wslgit.log: Permission denied
/usr/bin/wslgit.sh: line 179: /usr/bin/wslgit.log: Permission denied
/usr/bin/wslgit.sh: line 179: /usr/bin/wslgit.log: Permission denied
/usr/bin/wslgit.sh: line 179: /usr/bin/wslgit.log: Permission denied
/usr/bin/wslgit.sh: line 180: /usr/bin/wslgit.log: Permission denied

Edit, it looks like it works fine if I switch to https and then use a portable windows git credential manager. Oh well, I guess?

@hangxingliu
Copy link
Owner

@MostHated I will fix the permission trouble of logging later

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

4 participants