You can refer to it either using ./-filename
or some command will allow you to put it after double dash:
rm -- -filename
More Related Contents:
- Looping through the content of a file in Bash
- Why should eval be avoided in Bash, and what should I use instead?
- How to redirect output to a file and stdout
- How to kill a child process after a given timeout in Bash?
- ./configure : /bin/sh^M : bad interpreter [duplicate]
- The ‘eval’ command in Bash and its typical uses
- How to join multiple lines of file names into one with custom delimiter?
- Linux: copy and create destination dir if it does not exist
- How to redirect the output of the time command to a file in Linux?
- Get program execution time in the shell
- ‘&&’ vs. ‘&’ with the ‘test’ command in Bash
- How to redirect stderr and stdout to different files in the same line in script?
- How to use ‘cp’ command to exclude a specific directory?
- Linux bash: Multiple variable assignment
- How to sort a file in-place?
- What is the meaning of a double dollar sign in bash/Makefile?
- Is it OK to use the same input file as output of a piped command?
- Run cron job only if it isn’t already running
- Redirecting command output in docker
- When to wrap quotes around a shell variable?
- How to get file creation date/time in Bash/Debian?
- Disable and re-enable address space layout randomization only for myself
- How to join multiple lines of filenames into one with custom delimiter
- Check if a variable exists in a list in Bash
- Doesn’t sh support process substitution
- How to perform a for-each loop over all the files under a specified path?
- Run script with rc.local: script works, but not at boot
- Maximum number of Bash arguments != max num cp arguments?
- Write a bash shell script that consumes a constant amount of RAM for a user defined time [closed]
- Using “$RANDOM” to generate a random string in Bash