touch

Aliases: 
  • new
  •  
    Parameters:
    Name Type Required Default Hint
    file string true File to create
    force boolean false false If forced, then file will be recreated even if it exists

    Command Usage

    Create a new file according to its name if it does not exist. If it exists, modify its last updated date and time to now.

    touch file.txt
    Use the force parameter to overwrite the contents of the file to be empty even if it exists.
    touch file.txt --force