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

Filenames with special characters e.g. ! are not handled correctly #64

Closed
gsbabil opened this issue Dec 1, 2013 · 4 comments
Closed
Labels
👆 clink Upstream issue in clink.

Comments

@gsbabil
Copy link

gsbabil commented Dec 1, 2013

Cmder has trouble handling filenames with special characters such as !. It doesn't make any difference if the name is quoted in single or double quotes.

e.g. both of the commands below would fail since !! gets expanded by the shell.

move "blah!!.mkv" "blah.mkv"
move 'blah!!.mkv' 'blah.mkv'
@Vivix
Copy link
Contributor

Vivix commented Dec 1, 2013

You can escape it with ^!^!, this problem seems to stem from clink, but I couldn't find any configuration options for it to halt history expansion. There's some options to explore, configuration files for clink, or cmder, but until then ^ escape is your friend.

@gsbabil
Copy link
Author

gsbabil commented Dec 2, 2013

@Vivix thanks a lot. Not sure if Cmder can implemente it, but It would have been nicer to have \ as the escape character as in all other shells.

@Vivix
Copy link
Contributor

Vivix commented Dec 2, 2013

No problem. If you want something closer to Linux you can try cygwin and such with bash or other shells (can't remember if sh or zsh is available.). Implementing \ would not be a good idea in a cmd consistent environment.

@Jackbennett
Copy link
Contributor

This works now so long as the filename with special chars is in quotes or the special chars escaped

mv "blah!!.txt" blah.txt
mv 'blah!!.txt' blah.txt
mv blah^!^!.txt blah.txt

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

No branches or pull requests

3 participants