In Linux, can we use some other character other than forward slash /.
I don’t want to use / for moving between folders. I am just doing some experiment in scripting, so was just curious to know.
e.g. Instead of cd ../../ I may use cd ..-..- or any other character which a file name can have.
The
/is not an artefact of the operating system, it is a notation agreed upon by the interpreters, I’d say. Therefore you have two alternatives to replace it:cdfor example by usin alias definitions. Those can replace the ‘alternate hierarchy character’ you suggest.But be aware of the fact that you have to escape that character if it is contained in an ordinary file or folder name.
Oh, and one more kind of half an alternative:
/. That way you still use that character, but it looks totally different.Ah, and…
powershellinwine, then you can use MS-Windows style back slashes (\) instead of the normal forward slashes.