0

Truncate a file or create an empty file

> /path/to/file

November 29, 2023bashoneliners

Explanation

With the redirection operator > we write nothing to a file, truncating an existing file or creating a new empty file.