Thumbnail

rani/cscroll.git

Clone URL: https://git.buni.party/rani/cscroll.git

commit db6596ce3fafb25b19bc728060df1132597cecdc Author: rani <clagv.randomgames@gmail.com> Date: Mon Aug 29 20:47:15 2022 +0000 No-op for -h flag diff --git a/README.md b/README.md index c1b0319..a53c425 100644 --- a/README.md +++ b/README.md @@ -336 +337 @@ File colors can also be customized. ([see variables](#variables))    * `-A`: Show dotfiles in listings but exclude . and ..  * `-a`: (Only available in oneshot mode) List all dotfiles including . and .. +* `-h`: No-op: for compatibility with ls  * `-p`: Print the path cscroll ends in. Useful for commands like `cd $(cscroll -p)` to cd into the last directory  * `-nc`: Turn off coloring. cscroll will run in black and white mode  * `-ni`: (If compiled with icons) turn off icons on start diff --git a/src/main.c b/src/main.c index 5aa3931..6f6876f 100644 --- a/src/main.c +++ b/src/main.c @@ -436 +438 @@ int main(int argc, char ** argv) {   } else if (!strcmp(argv[i], "-a")) {   show_dot_dirs = true;   show_dot_files = true; + } else if (!strcmp(argv[i], "-h")) { + // no-op   } else if (!strcmp(argv[i], "--help")) {   help();   } else if (!strcmp(argv[i], "--oneshot")) { @@ -4716 +4737 @@ void help(void) {   " -A Show dotfiles except . and ..\n"   " -a Show all dotfiles, including . and ..\n"   " Only available in oneshot mode\n" + " -h No-op: for compatibility purposes\n"   " -nc Turn off colors\n"  #if ICONS   " -ni Turn off icons\n"