Search
 
SCRIPT & CODE EXAMPLE
 

SHELL

create file in linux

touch <filename>.<extension>
Comment

create file in linux

sudo nano <filename.extension>

Example:
cd /
cd /var/www/html
sudo nano Form.php
Comment

linux make file

touch file1.txt #Create file1.txt
Comment

linux terminal create file

/* only create file */
touch myFile.html

/* create and open to edit */
nano myFile.html
vim myFile.html
Comment

linux create file

#solution 1
touch filename

#solution 2
> filename # or >> filename

#solution 3
cat > filename
Comment

create file linux

//will create test.txt
sudo touch test.txt
Comment

creating new files in linux

// To create a new file run the cat command followed by the redirection operator > and the name of the file you want to create.
// Press Enter type the text and once you are done press the CRTL+D to save the files.
cat > file1.txt
Comment

PREVIOUS NEXT
Code Example
Shell :: rec: command not found 
Shell :: batch file with flags 
Shell :: github action on every commit 
Shell :: llaravel sanctum 
Shell :: powershell sharepoint 2010 update item 
Shell :: mac send terminal output to clipboard 
Shell :: git push main 
Shell :: homebrew nvm install 
Shell :: git tag older commit 
Shell :: how to check my mint version 
Shell :: windows powershell 
Shell :: pyinquier install 
Shell :: apache2 default url 
Shell :: bash find string in program output 
Shell :: git copy changes from one branch to another 
Shell :: powershell array index 
Shell :: command can be used to find files or folders matching a particular search pattern in linux 
Shell :: git clean all submodules on branch switch 
Shell :: git clone vs add remote 
Shell :: Install command-line ipfs 
Shell :: delete list of packages linux 
Shell :: ubuntu command change line in file 
Shell :: select loop bash 
Shell :: Failed to install expo package with error: yarnpkg exited with non-zero code: 1 yarnpkg exited with non-zero code: 1 
Shell :: ansible playbook to set passwordless sudo 
Shell :: git alias variables 
Shell :: git ultiple branch delete 
Shell :: bash setting home 
Shell :: set up vim in zsh 
Shell :: ubuntu change primary group 
ADD CONTENT
Topic
Content
Source link
Name
3+7 =