Here’s how to do it.

-a and -m options

These two options update the access and modification time respectively.

Using them should be no problem at all.

Terminal window showing the manual page for the Mutt email client on Linux

This option is complex to fully describe it here.

On the other hand (-t) uses a simple stamp that you are confined to use.

The stamp is [[CC]YY]MMDDhhmm[.ss].

a-person-typing-on-logitech-g515-lightspeed-tkl-keyboard

[CC] is for century and you may ignore it and ignore the seconds as well.

If you ignore [CC] the command will substitute it depending on what you enter as year.

While the second command will set it to: 15th April 1988 which is in a different century.

Article image

If no year is specified it will be set to the current year.

Creating Empty Files

The second and most famous usage of the touch command is creating empty files.

In other words, you might use it to create logs.

Tocuh options table