I have file named -
. cat -
means standart input, but what if I want to open file, which name is -
? I already searched a lot of information and asked some people, but they even don't know how to do it.
Asked
Active
Viewed 52 times
1

Anisimov
- 25
- 1
- 8
-
1Duplicate of https://stackoverflow.com/questions/42187323/how-to-open-a-dashed-filename-using-terminal – Fabio Feb 18 '22 at 09:42
2 Answers
1
Include the relative path of the file
cat ./-

Fabio
- 299
- 3
- 11
-
Thanks! It helped for me. I will accept your answer 8 minutes later because of rules. – Anisimov Feb 18 '22 at 09:42
0
You can use command like:
cat <-
this explicitly will redirect the file to stdin

Romeo Ninov
- 6,538
- 1
- 22
- 31