How do I create a bash script?

Duyên Trương

New member
How do I create a bash script?
Answer
How to create a file in Linux from terminal window?
  1. Create an empty text file named foo.txt: touch foo.bar. …
  2. Make a text file on Linux: cat > filename.txt.
  3. Add data and press CTRL + D to save the filename.txt when using cat on Linux.
  4. Run shell command: echo ‘This is a test’ > data.txt.
  5. Append text to existing file in Linux:
20 дек. 2020 г.
 

Tìm kiếm

Back
Top