Views:
91,936β
Votes: 5β
Tag :
ubuntu-touch
Link:
π See Original Answer on Ask Ubuntu β§ π
URL:
https://askubuntu.com/q/896957
Title:
writing a text file in the terminal with touch
ID:
/2017/03/26/writing-a-text-file-in-the-terminal-with-touch
Created:
March 26, 2017
Upload:
September 15, 2024
Layout: post
TOC:
false
Navigation: false
Copy to clipboard: false
If I understand your question correctly you want to use:
echo "hello" > ~/Desktop/new_file.txt && echo "world" >> ~/Desktop/new_file.txt
Then to check the results use cat ~/Desktop/new_file.txt
which shows:
hello
world
Thereβs a shorter way of doing this but Iβm kind of new to Linux myself.