3 ms·
Unless your ssh'd into a machine, it's annoying to type long dir's. What's worse is compensating for spaces in filenames.
by quackerhacker 13y ago
Unless your ssh'd into a machine, it's annoying to type long dir's. What's worse is compensating for spaces in filenames.
- freework 13y agoThats what tab completion is for.
- quackerhacker 13y agoThank you freework, didn't know about that one (embarrassing as it is to admit). Still sucks dealing with spaces when it comes to command processes like ffmpeg -i <no_tab>...but awesome for cd'ing or ls'ing!
- kanemathers 13y agoJust prefix the space with a backslash. Eg: ``$ ls /foo/bar/my\ directory/``. With that backslash in place, you can continue your tab-completion.
- iSnow 13y agoStill, on some international keyboards, backspace is hard to reach, eg. on a German Mac keyboard, is it <alt><shift>7. So don't put spaces in path names, it's a bitch to work with.
- emillon 13y agoYou can quote the space: mkdir x\ y cd x' 'y (or the entire part: cd 'x y')
- quackerhacker 13y agoYup, that's what I do too, or %20 if its a url
- deleted 13y ago[deleted]
- J_Darnley 13y agoUnix/Linux/whatever should have just forbidden spaces in filenames in the first place since none of the basic tools make it easy iterate over a list of filenames with spaces correctly.
- gizmo686 13y agoAt least UNIX doesn't have a space in the path of the main programs directory (I'm looking at you Windows). Also, many of the basic tools have a -0 option which uses the null character to replace many uses of space. Still far from an adequate solution though.
- quackerhacker 13y agoOhh yeah! This is where my initial frustrations have always been for spaces...mounting an NTFS-3G or URL encodings.