From 9cfeb6500e8fca7d6e03436a6ab3b5901c4fd6f5 Mon Sep 17 00:00:00 2001 From: Uggla Date: Fri, 8 Nov 2024 22:21:58 +0100 Subject: [PATCH 1/2] Add command line optional argument ftime - This argument can take 3 value atime (access), btime(birth), mtime(modification). - This argument will be used to change the file time displayed accordingly. --- doc/lsd.md | 17 +-- src/app.rs | 12 +++ src/config_file.rs | 3 + src/flags.rs | 4 + src/flags/ftime.rs | 261 +++++++++++++++++++++++++++++++++++++++++++++ src/meta/date.rs | 2 +- 6 files changed, 291 insertions(+), 8 deletions(-) create mode 100644 src/flags/ftime.rs diff --git a/doc/lsd.md b/doc/lsd.md index 78a120465..f467321f7 100644 --- a/doc/lsd.md +++ b/doc/lsd.md @@ -96,7 +96,7 @@ lsd is a ls command with a lot of pretty colours and some other stuff to enrich : Specify the blocks that will be displayed and in what order [possible values: permission, user, group, size, date, name, inode, git] `--color ...` -: When to use terminal colours [default: auto] [possible values: always, auto, never] +: When to use terminal colours [default: auto] [possible values: always, auto, never] `--date ...` : How to display date [possible values: date, locale, relative, +date-time-format] [default: date] @@ -104,29 +104,32 @@ lsd is a ls command with a lot of pretty colours and some other stuff to enrich `--depth ...` : Stop recursing into directories after reaching specified depth +`--ftime