One point of consideration is if the truncated file is the same file or a new file with the same name. Of importance for log files that are still being written-to, or being tail
ed.
:> file
Works on both *nix and macOS to truncate a file in-place.
One point of consideration is if the truncated file is the same file or a new file with the same name. Of importance for log files that are still being written-to, or being tail
ed.
:> file
Works on both *nix and macOS to truncate a file in-place.