Skip to content Skip to sidebar Skip to footer

Linux Delete File Name Starting With Dash

Linux Delete File Name Starting With Dash. The files starting with dot (.) are very special in linux and are called dot files. How to delete the last record of a file using linux command.

How to delete and remove files on CentOS Linux nixCraft
How to delete and remove files on CentOS Linux nixCraft from www.cyberciti.biz

The files starting with dot (.) are very special in linux and are called dot files. We can write file names start with dash. This extra dash is necessary so that rm does not misinterpret the file name as an option.

How To Delete The Last Record Of A File Using Linux Command.


The double dash/double hyphen tells the command that no more command line options will be given. So how can rm recognize file name from option? Show activity on this post.

./Just Meanslook In The Current Directory (1.21).


We will use the following command. In this example we will write this is some. Files that begin with a hyphen (dash) can be tricky to remove because linux or unix will interpret the character after the dash as an option.

As We Can See The File Name Is Specified After Double Dash.


If you move files to linux, or have git bash on your pc, and have access to the find command, you might also be able to do this: Or /* or * or some other wildcard which could cascade delete your operating system. In linux, you can remove/delete directories with the rmdir and rm.

Tour Start Here For A Quick Overview Of The Site.


This extra dash is necessary so that rm does not misinterpret the file name as an option. Creating, editing, renaming and deleting of such files are straight forward. Asked jun 18, 2019 in operating systems by praveen (18.0k points).

Using The Redundant./ Directory Information Prevents The Dash From Occurring At The Beginning Of The Filename, And.


In this quick tip i am going to show you to delete or copy files with names that contain strange characters on linux. We will use echo command and redirect the data into the file. Delete a file starting with a dash/hypen on linux on the command line.

Post a Comment for "Linux Delete File Name Starting With Dash"