Skip to Content
gnux

-r, --reference

Use this FILE's times instead of current time.

An option of touchx.

Usage

touchx -r FILE FILE...
touchx --reference=FILE FILE...

Details

ShortLongValueDefaultMeaning
-r--referenceFILEuse this FILE's times instead of current time

Examples

Give one file the timestamps of another

touchx -r original.jpg edited.jpg

Copy just the modification time, and only to files that already exist

touchx -c -m -r original.jpg edited.jpg report.pdf

Help in the terminal

gnux help touchx --reference

On this page