DEV Community

Sachin
Sachin

Posted on

Linux File guide

In a linux have 4 ways to create a file

cat

it command is - cat > filename enter it can write the file and ctrl + d exit the
file


see that image

touch

it create the empty file
touch filename enter
show the ls command

nano

it is type of editor n
command - nano filename
and exit to ctrl + x and it type Y

  • Vi/ vim vi filename it have two mode insert mode press i to typing the file

command mode type Esc :wq! w- save and q quit and ! forcefully

Top comments (0)