Intellipaat Back

Explore Courses Blog Tutorials Interview Questions
0 votes
2 views
in Linux by (18.4k points)

By mistake I created a file which a name using a backslash \:

>ls -l

total 0

-rw-rw---- 1 user group  0 Jul  3 21:34 \

How to delete it?

1 Answer

0 votes
by (36.8k points)

To pass a \ in the argument to the command, you just need to "quote" or "escape" it, you can do it by wrapping it with single-quotes:

rm '\'

or by prefixing it with another backslash:

rm \\

To know about Linux join the Linux training

Related questions

0 votes
1 answer
0 votes
1 answer
0 votes
1 answer
0 votes
1 answer
asked Dec 23, 2020 in Linux by blackindya (18.4k points)
0 votes
1 answer

31k questions

32.8k answers

501 comments

693 users

Browse Categories

...