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

"ipfs files" commands are escaping windows path slashes #4615

Closed
Xendipity opened this issue Jan 26, 2018 · 1 comment
Closed

"ipfs files" commands are escaping windows path slashes #4615

Xendipity opened this issue Jan 26, 2018 · 1 comment

Comments

@Xendipity
Copy link

Version information:

go-ipfs version: 0.4.13-
Repo version: 6
System version: amd64/windows
Golang version: go1.9.2

Type: bug

Severity: High?

Description:

While using the go-ipfs cli on a windows git-bash terminal, I'm running into an issue where the ipfs files commands are escaping forward slashes: /:

Fails:

$ ipfs files mkdir /breakfast
Error: Paths must start with a leading slash.

Works:

$ ipfs files mkdir //breakfast

I have this general problem with all ipfs files commands. Looked around through some issues and this one could be related to another recent issue #4602 but you guys would know more.

@Stebalien
Copy link
Member

This is actually an issue with git-bash and I'm not sure there's much we can do about it. Unfortunately, git-bash recognizes that ipfs is a windows command, sees that /breakfast is a path, and then rewrites it as a windows path (probably as something like C:\path\to\git\bash\root\breakfast).

Apparently, setting MSYS_NO_PATHCONV=1 may fix this (git bash uses msys). Alternatively, passing a double leading slash will tell git bash to not rewrite the path.

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