Here is how to create an empty file in #Linux or #Unix:

touch file1 # method 1

:>file2 # method 2

>file3 # method 3 (will fail with the shellcheck linter https://www.cyberciti.biz/programming/improve-your-bashsh-shell-script-with-shellcheck-lint-script-analysis-tool/)

Reply to this note

Please Login to reply.

Discussion

No replies yet.