diff options
author | Tavian Barnes <tavianator@tavianator.com> | 2016-12-20 22:05:21 -0500 |
---|---|---|
committer | Tavian Barnes <tavianator@tavianator.com> | 2016-12-20 22:05:21 -0500 |
commit | 9b30634a234659c7dd87073c00affdcdec74c5ed (patch) | |
tree | 46c6ad2d3b4390dab75f91892525df7dc17c7f87 | |
parent | 4b6e5737241feacc0764e56e438cabee2ff3429e (diff) | |
download | bfs-9b30634a234659c7dd87073c00affdcdec74c5ed.tar.xz |
Add some text to the -help output
-rw-r--r-- | parse.c | 28 |
1 files changed, 27 insertions, 1 deletions
@@ -1736,11 +1736,37 @@ static struct expr *parse_warn(struct parser_state *state, int warn, int arg2) { * "Parse" -help. */ static struct expr *parse_help(struct parser_state *state, int arg1, int arg2) { - printf("Usage: %s [arguments...]\n\n", state->command); + printf("Usage: %s [flags...] [paths...] [expression...]\n\n", state->command); printf("bfs is compatible with find; see find -help or man find for help with find-\n" "compatible options :)\n\n"); + printf("flags (-H/-L/-P etc.), paths, and expressions may be freely mixed in any order.\n\n"); + + printf("POSIX find features:\n"); + printf(" ( EXPRESSION )\n"); + printf(" ! EXPRESSION\n"); + printf(" EXPRESSION [-a] EXPRESSION\n"); + printf(" EXPRESSION -o EXPRESSION\n\n"); + printf(" -H, -L, -name, -path, -xdev, -prune, -perm, -type, -links, -user, -group,\n"); + printf(" -size, -atime, -ctime, -mtime, -exec ... ;, -ok ... ;, -print, -newer, -depth\n\n"); + + printf("GNU find features:\n"); + printf(" -not EXPRESSION\n"); + printf(" EXPRESSION -and EXPRESSION\n"); + printf(" EXPRESSION -or EXPRESSION\n"); + printf(" EXPRESSION , EXPRESSION\n\n"); + printf(" -P, -D, -O, -daystart, -follow, -regextype, -warn, -nowarn, -d, -maxdepth,\n"); + printf(" -mindepth, -mount, -noleaf, -ignore_readdir_race, -noignore_readdir_race,\n"); + printf(" -amin, -anewer, -cmin, -cnewer, -mmin, -empty, -false, -gid, -ilname, -iname,\n"); + printf(" -inum, -ipath, -iwholename, -iregex, -lname, -newerXY, -wholename, -regex,\n"); + printf(" -readable, -writable, -executable, -samefile, -true, -uid, -used, -xtype,\n"); + printf(" -delete, -execdir ... ;, -okdir ... ;, -print0, -fprint, -fprint0, -quit,\n"); + printf(" -help, -version\n\n"); + + printf("BSD find features:\n"); + printf(" -E, -d, -x, -depth N, -gid NAME, -uid NAME, -size N[ckMGTP], -sparse\n\n"); + printf("Extra features:\n" " -color, -nocolor: Turn on or off file type colorization.\n\n" " -hidden, -nohidden: Match hidden files, or filter them out.\n\n"); |