{"id":15148736,"url":"https://github.com/raforg/rawhide","last_synced_at":"2025-10-24T05:30:31.565Z","repository":{"id":149946608,"uuid":"459471465","full_name":"raforg/rawhide","owner":"raforg","description":"find files using pretty C expressions","archived":false,"fork":false,"pushed_at":"2024-11-20T04:07:54.000Z","size":704,"stargazers_count":47,"open_issues_count":0,"forks_count":5,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-01-30T23:41:20.348Z","etag":null,"topics":["c","command-line","cygwin","file","find","freebsd","linux","macos","netbsd","openbsd","pcre2","solaris","unix"],"latest_commit_sha":null,"homepage":"https://raf.org/rawhide/","language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/raforg.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG","contributing":null,"funding":null,"license":"COPYING","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2022-02-15T07:26:07.000Z","updated_at":"2025-01-23T11:33:30.000Z","dependencies_parsed_at":null,"dependency_job_id":"6b3b171a-1107-4534-a6ad-cf8d053332c5","html_url":"https://github.com/raforg/rawhide","commit_stats":{"total_commits":80,"total_committers":2,"mean_commits":40.0,"dds":"0.012499999999999956","last_synced_commit":"73ed9a23234f44544ed801a901f727386bfe8b81"},"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/raforg%2Frawhide","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/raforg%2Frawhide/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/raforg%2Frawhide/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/raforg%2Frawhide/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/raforg","download_url":"https://codeload.github.com/raforg/rawhide/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":237915423,"owners_count":19386724,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["c","command-line","cygwin","file","find","freebsd","linux","macos","netbsd","openbsd","pcre2","solaris","unix"],"created_at":"2024-09-26T13:22:18.029Z","updated_at":"2025-10-24T05:30:31.552Z","avatar_url":"https://github.com/raforg.png","language":"C","readme":"# README\n\n*rawhide* - (*rh*) find files using pretty C expressions\n\n# INTRODUCTION\n\n*Rawhide* (*rh*) lets you search for files on the command line using\nexpressions and user-defined functions in a mini-language inspired by *C*.\nIt's like *find(1)*, but more fun to use. Search criteria can be very\nreadable and self-explanatory and/or very concise and typeable, and you can\ncreate your own lexicon of search terms. The output can include lots of\ndetail, like *ls(1)*.\n\n# DESCRIPTION\n\n*Rawhide* (*rh*) searches the filesystem, starting at each given path, for\nfiles that make the given search criteria expression true. If no search\npaths are given, the current working directory is searched.\n\nThe search criteria expression can come from the command line (with the `-e`\noption), from a file (with the `-f` option), or from standard input\n(*stdin*) (with `-f-`). If there is no explicit `-e` option expression, *rh*\nlooks for an implicit expression among any remaining command line arguments.\nIf no expression is specified, the default search criteria is the expression\n`1`, which matches all filesystem entries.\n\nAn *rh* expression is a *C*-like expression that can call user-defined\nfunctions. These expressions can contain all of *C*'s conditional, logical,\nrelational, equality, arithmetic, and bit operators.\n\nNumeric constants can be decimal, octal, or hexadecimal integers. Decimal\nconstants can have scale units (e.g., `10K`).\n\nThere are built-in symbols that represent each candidate file's inode\nmetadata. These are the fields in the corresponding *stat(2)* structure\n(e.g., `st_mode`, `st_uid`, `st_size`, `st_mtime`, ...). See *stat(2)* for\ndetails. For convenience, the `\"st_\"` prefix is omitted from the symbol\nnames (e.g., `st_mtime` is used as `mtime`).\n\nOther built-in symbols represent the constants defined by *C*'s\n`\u003csys/stat.h\u003e` header file. These are useful for interpreting the `mode` in\norder to identify file types and permissions. The `\"S_\"` prefix is omitted\nfrom the symbol names (e.g., `S_IFMT` is used as `IFMT`).\n\nOther built-in symbols represent various useful values and constants,\ncontrol flow, more file information, and candidate symlink target inode\nmetadata.\n\nFile glob patterns and *Perl*-compatible regular expressions (regexes) can\nbe used to match files by their name, path, symlink target path, body, file\ntype description, MIME type, access control list, and extended attributes.\n\nSearch criteria can also include comparisons with the inode metadata of\narbitrary reference files, and the exit success status of arbitrary shell\ncommands.\n\nFunctions are a means of referring to an expression by name. They allow\ncomplex expressions to be composed of simpler ones. They also allow you to\ncreate your own lexicon of search terms for finding files.\n\nThere is a default standard library of functions to start with. It provides\na high-level interface to the built-in symbols mentioned above, and makes\n*rh* easy to use. See *rawhide.conf(5)* for details.\n\n# SYNOPSIS\n\n     usage: rh [options] [--] [path...]\n     options:\n       -h --help    - Show this help message, then exit\n       -V --version - Show the version message, then exit\n       -N           - Don't read system-wide config (/etc/rawhide.conf)\n       -n           - Don't read user-specific config (~/.rhrc)\n       -f-          - Read functions and/or expression from stdin\n       -f fname     - Read functions and/or expression from a file\n      [-e] 'expr'   - Read functions and/or expression from the cmdline\n\n     traversal options:\n       -r           - Only search one level down (same as -m1 -M1)\n       -m #         - Override the default minimum depth (0)\n       -M #         - Override the default maximum depth (system limit)\n       -D           - Depth-first searching (contents before directory)\n       -1           - Single filesystem (don't cross filesystem boundaries)\n       -y           - Follow symlinks on the cmdline and in reference files\n       -Y           - Follow symlinks encountered while searching as well\n\n     alternative action options:\n       -x 'cmd %s'  - Execute a shell command for each match (racy)\n       -X 'cmd %S'  - Like -x but run from each match's directory (safer)\n       -U -U -U     - Unlink matches (but tell me three times), implies -D\n\n     output action options:\n       -l           - Output matching entries like ls -l (but unsorted)\n       -d           - Include device column, implies -l\n       -i           - Include inode column, implies -l\n       -B           - Include block size column, implies -l\n       -s           - Include blocks column, implies -l\n       -S           - Include space column, implies -l\n       -g           - Exclude user/owner column, implies -l\n       -o           - Exclude group column, implies -l\n       -a           - Include atime rather than mtime column, implies -l\n       -u           - Same as -a (like ls(1))\n       -c           - Include ctime rather than mtime column, implies -l\n       -v           - Verbose: All columns, implies -ldiBsSac unless -xXU0Lj\n       -0           - Output null chars instead of newlines (for xargs -0)\n       -L format    - Output matching entries in a user-supplied format\n       -j           - Output matching entries as JSON (same as -L \"%j\\n\")\n\n     path format options:\n       -Q           - Enclose paths in double quotes\n       -E           - Output C-style escapes for control characters\n       -b           - Same as -E (like ls(1) on many systems)\n       -q           - Output ? for control characters (default if tty)\n       -p           - Append / indicator to directories\n       -t           - Append most type indicators (one of / @ = | \u003e)\n       -F           - Append all type indicators (one of * / @ = | \u003e)\n\n                        * executable\n                        / directory\n                        @ symlink\n                        = socket\n                        | fifo\n                        \u003e door (Solaris only)\n\n     other column format options:\n       -H or -HH    - Output sizes like 1.2K 34M 5.6G etc., implies -l\n       -I or -II    - Like -H but with units of 1000, not 1024, implies -l\n       -T           - Output mtime/atime/ctime in ISO format, implies -l\n      '-#'          - Output numeric user/group IDs (not names), implies -l\n\n     debug option:\n      '-?' spec     - Output debug messages: spec can include any of:\n                        cmdline, parser, traversal, exec, all, extra\n\n     rh (rawhide) finds files using pretty C expressions.\n     See the rh(1) and rawhide.conf(5) manual entries for more information.\n\n     C operators:\n       ?:  ||  \u0026\u0026  |  ^  \u0026  == !=  \u003c \u003e \u003c= \u003e=  \u003c\u003c \u003e\u003e  + -  * / %  - ~ !\n\n     Rawhide tokens:\n       \"pattern\"  \"pattern\".modifier  \"/path\".field  \"cmd\".sh  \"cmd\".ush\n       {pattern}  {pattern}.modifier  {/path}.field  {cmd}.sh  {cmd}.ush\n       123 0777 0xffff  1K 2M 3G  1k 2m 3g  $user @group  $$ @@\n       [yyyy/mm/dd] [yyyy/mm/dd hh:mm:ss]\n\n     Glob pattern notation:\n       ? * [abc] [!abc] [a-c] [!a-c]\n       ?(a|b|c) *(a|b|c) +(a|b|c) @(a|b|c) !(a|b|c)\n       Some ksh extended glob patterns are available here (see fnmatch(3))\n\n     Pattern modifiers:\n                     .i            .re           .rei\n       .path         .ipath        .repath       .reipath\n       .link         .ilink        .relink       .reilink\n       .body         .ibody        .rebody       .reibody\n       .what         .iwhat        .rewhat       .reiwhat\n       .mime         .imime        .remime       .reimime\n       .acl          .iacl         .reacl        .reiacl\n       .ea           .iea          .reea         .reiea\n       .sh           .ush\n       Case-insensitive glob pattern matching is available here (i)\n       Perl-compatible regular expressions are available here (re)\n       File types and MIME types are available here (what, mime)\n       Access control lists are available here (acl)\n       Extended attributes are available here (ea)\n\n     Built-in symbols:\n       dev           major         minor         ino           mode\n       nlink         uid           gid           rdev          rmajor\n       rminor        size          blksize       blocks        atime\n       mtime         ctime         attr          proj          gen\n       nouser        nogroup       readable      writable      executable\n       strlen        depth         prune         trim          exit\n       now           today         second        minute        hour\n       day           week          month         year          IFREG\n       IFDIR         IFLNK         IFCHR         IFBLK         IFSOCK\n       IFIFO         IFDOOR        IFMT          ISUID         ISGID\n       ISVTX         IRWXU         IRUSR         IWUSR         IXUSR\n       IRWXG         IRGRP         IWGRP         IXGRP         IRWXO\n       IROTH         IWOTH         IXOTH         texists       tdev\n       tmajor        tminor        tino          tmode         tnlink\n       tuid          tgid          trdev         trmajor       trminor\n       tsize         tblksize      tblocks       tatime        tmtime\n       tctime        tstrlen\n\n     Reference file fields:\n       .exists       .dev          .major        .minor        .ino\n       .mode         .type         .perm         .nlink        .uid\n       .gid          .rdev         .rmajor       .rminor       .size\n       .blksize      .blocks       .atime        .mtime        .ctime\n       .attr         .proj         .gen          .strlen       .inode\n       .nlinks       .user         .group        .sz           .accessed\n       .modified     .changed      .attribute    .project      .generation\n       .len\n\n     System-wide and user-specific functions can be defined here:\n       /etc/rawhide.conf          ~/.rhrc\n       /etc/rawhide.conf.d/*      ~/.rhrc.d/*\n\n# EXAMPLES\n\nThe following are examples of *rh* expressions. Where multiple versions are\ngiven, the first one only uses built-in symbols, and the rest usually make\nuse of the standard library in `/etc/rawhide.conf` (or similar) as well. See\n*rawhide.conf(5)* for details.\n\nFind files that are owned by the user `drew`, and are writable by other\npeople:\n\n        (uid == $drew) \u0026\u0026 (mode \u0026 022) # uid and mode are built-in\n        (uid == $drew) \u0026\u0026 (gw | ow)    # gw and ow are in /etc/rawhide.conf\n\nFind files that are owned by `root`, have the setuid bit set, and are\nworld-writable:\n\n        !uid \u0026\u0026 (mode \u0026 ISUID) \u0026\u0026 (mode \u0026 02) # uid, mode, ISUID: built-in\n        roots \u0026\u0026 setuid \u0026\u0026 other_writable     # the rest: /etc/rawhide.conf\n        roots \u0026\u0026 setuid \u0026\u0026 world_writable\n        roots \u0026\u0026 suid \u0026\u0026 ow\n        roots \u0026\u0026 suid \u0026\u0026 ww\n\nFind executable files that are larger than 10KiB, and have not been executed\nin the last 24 hours:\n\n        (mode \u0026 0111) \u0026\u0026 (size \u003e 10 * 1024) \u0026\u0026 (atime \u003c now - 24 * hour)\n        any(0111) \u0026\u0026 (size \u003e 10 * KiB) \u0026\u0026 accessed \u003c ago(24 * hours)\n        anyx \u0026\u0026 sz \u003e 10K \u0026\u0026 atime \u003c ago(day)\n\nFind *C* source files that are smaller than 4KiB, and other files that are\nsmaller than 32KiB:\n\n        size \u003c (\"*.c\" ? 4K : 32K)     # size: built-in\n        size \u003c (\"*.c\" ? 4 : 32) * KiB # KiB: /etc/rawhide.conf\n\nFind files that are an exact multiple of 1KiB in size:\n\n        (size % 1024) == 0\n        !(sz % 1K)\n\nFind files that were last modified during March, 1982:\n\n        mtime \u003e= [1982/3/1] \u0026\u0026 mtime \u003c [1982/4/1]\n        modified \u003e= [1982/3/1] \u0026\u0026 modified \u003c [1982/4/1]\n\nFind files that have been read since they were last written:\n\n        atime \u003e mtime\n        accessed \u003e modified\n\nFind files whose names are between 4 and 10 bytes in length:\n\n        strlen \u003e= 4 \u0026\u0026 strlen \u003c= 10\n        len \u003e= 4 \u0026\u0026 len \u003c= 10\n\nFind files that are at a relative depth of 3 or more below the starting\nsearch directory:\n\n        depth \u003e= 3\n\nThis expression finds `*.c` files. However, it will not search in any\ndirectories named `bin` or `tmp`. If these file names are encountered,\nthe `prune` built-in is evaluated, preventing the current path from\nmatching, and preventing further searching below the current path.\n\n        (\"tmp\" || \"bin\") ? prune : \"*.c\"\n        (\"tmp\" || \"bin\") \u0026\u0026 prune || \"*.c\"\n\nFind files that were modified after another file was last modified:\n\n        mtime \u003e \"/otherfile\".mtime\n        modified \u003e \"/otherfile\".modified\n\nFind files that are larger than one file and smaller than another file:\n\n        size \u003e \"/somefile\".size \u0026\u0026 size \u003c \"/otherfile\".size\n        sz \u003e \"/somefile\".sz \u0026\u0026 sz \u003c \"/otherfile\".sz\n\nFind files with holes (for filesystems without transparent compression):\n\n        (mode \u0026 IFMT) == IFREG \u0026\u0026 size \u0026\u0026 blocks \u0026\u0026 (blocks * 512) \u003c size\n        file \u0026\u0026 size \u0026\u0026 blocks \u0026\u0026 space \u003c size\n\nNote: The above doesn't take indirect blocks into account. It's just a heuristic.\n\nFind regular files with multiple hard links:\n\n        (mode \u0026 IFMT) == IFREG \u0026\u0026 nlink \u003e 1\n        file \u0026\u0026 nlinks \u003e 1\n        f \u0026\u0026 nlink \u003e 1\n\nFind all hard links to a particular file:\n\n        (dev == \"/path\".dev) \u0026\u0026 (ino == \"/path\".ino)\n        (dev == \"/path\".dev) \u0026\u0026 (ino == \"\".ino) # Implicit 2nd reference\n\nFind devices with the same device driver as `/dev/tty`:\n\n        rmajor == \"/dev/tty\".rmajor\n\nFind symlinks whose target paths are relative:\n\n        \"[!/]*\".link\n\nFind symlinks whose ultimate targets are on a different filesystem:\n\n        (mode \u0026 IFMT) == IFLNK \u0026\u0026 texists \u0026\u0026 tdev != dev\n        symlink \u0026\u0026 target_exists \u0026\u0026 target_dev != dev\n        l \u0026\u0026 texists \u0026\u0026 tdev != dev\n        texists \u0026\u0026 tdev != dev\n\nFind symlinks whose ultimate targets don't exist:\n\n        (mode \u0026 IFMT) == IFLNK \u0026\u0026 !texists\n        symlink \u0026\u0026 !target_exists\n        link \u0026\u0026 !texists\n        l \u0026\u0026 !texists\n        dangling\n        broken\n\nFind mountpoints under the current directory:\n\n        $ rh -1 -e 'dev != \".\".dev'\n\n**Note:** The above doesn't match *Linux* bind mounts because they don't\ninvolve a separate device.\n\nFind directories with no sub-directories (fast, for most filesystems, but\nnot *btrfs*):\n\n        $ rh -e 'd \u0026\u0026 nlink == 2'\n\nThe same, but works for *btrfs* (slow-ish, but demonstrates shell commands):\n\n        $ rh -e 'd \u0026\u0026 \"[ $(rh -red %S | wc -l) = 0 ]\".sh'\n        $ rh -e 'd \u0026\u0026 \"[ -z \\\"$(rh -red %S)\\\" ]\".sh'\n        $ rh -e 'd \u0026\u0026 {[ -z \"$(rh -red %S)\" ]}.sh'\n\nFind empty (readable) directories (fast-ish, and works for *btrfs*):\n\n        $ rh -e 'd \u0026\u0026 empty'\n\nFind symlinks whose immediate targets are also symlinks:\n\n        $ rh -l -e 'l \u0026\u0026 \"[ -L \\\"$(rh -L%%l %S)\\\" ]\".sh'\n        $ rh -l -e 'l \u0026\u0026 \"[ -L \\\"$(readlink %S)\\\" ]\".sh'\n        $ rh -l -e 'l \u0026\u0026 {[ -L \"$(readlink %S)\" ]}.sh'\n\nFind all hard links to all regular files that have multiple hard links (very\nslow):\n\n        # rh -e 'f \u0026\u0026 nlink \u003e 1' \\\n             -X 'rh -e \"(dev == \\\"$2\\\".dev) \u0026\u0026 (ino == \\\"\\\".ino)\" /; echo' \\\n             /\n\n**Note:** The use of `$2` instead of `%S` is to avoid the additional double\nquotes that would be introduced when `%S` is interpolated as `\"$2\"`. Using\n`%S` instead would leave the file name itself unquoted at the level of the\ninner shell.\n\n**Warning:** The above example is cute, but it is not safe for all file\nnames. If the file's base name contains certain things like `\\\\` or `\\\"` or\n`\"` it won't work, and if it contains `\";` that would trigger an arbitrary\ncode execution security vulnerability. In general, nested uses of *rh* like\nthis are not safe, unless you first check to ensure that no candidate files\nhave the characters `\\` or `\"` in their path, but even then, there would be\na race condition between the time that you check and the time that you use\nthe nested `rh`. In general, nested uses of *rh* are only safe when %s or %S\nis used as a separate command line argument, and not as part of the search\ncriteria expression.\n\nThe same, but for a single filesystem only (shorter, less slow, but still\nvery slow, and still unsafe):\n\n        # rh -1 -e 'f \u0026\u0026 nlink \u003e 1' -X 'rh -1e \"ino == \\\"$2\\\".ino\" /; echo' /\n\nFind 32-bit ELF executables:\n\n        $ rh -e 'f \u0026\u0026 anyx \u0026\u0026 sz \u003e 10k \u0026\u0026 \"ELF 32-bit*executable*\".what'\n\nFind text files that look like they have an ISO-8859-* encoding:\n\n        $ rh -e 'f \u0026\u0026 \"*ISO-8859* text\".what'\n        $ rh -e 'f \u0026\u0026 \"text/*; charset=iso-8859*\".mime'\n\nFind files that contain `TODO`:\n\n        $ rh -e '\"*TODO*\".body'\n        $ rh -e '\"TODO\".rebody'\n\nFind files using a *Perl*-compatible regular expression (regex):\n\n        $ rh -e '\"^[a-zA-Z0-9_]+[0-9][0-9][0-9]?\\..*[a-cz]$\".re'\n        $ rh -e '\"^\\w+\\d{2,3}\\..*[a-cz]$\".re'\n\nSee *perlre(1)*, *pcre2pattern(3)*, and *pcre2syntax(3)* for details.\n\nThe same, but with documentation:\n\n        $ rh -e '\"\n          ^         # Anchor the match to the start of the base name \n          \\w+       # Starts with at least one word character\n          \\d{2,3}   # Followed by two or three digits\n          \\.        # Followed by a literal dot\n          .*        # Followed by anything (or nothing)\n          [ a-c z ] # Ends with a, b, c, or z\n          $         # Anchor the match to the end of the base name\n        \".re'\n\nCase-insensitive search (anything with `abc` in the name):\n\n        $ rh -e '\"*ABC*\".i' # Case-insensitive glob of base name\n        $ rh -e '\"ABC\".rei' # Case-insensitive regex of base name\n\nFind files by their full path starting from the search directory (anything\nunder an `abc` directory):\n\n        $ rh -e '\"*/abc/*\".path'  # Glob of full path\n        $ rh -e '\"/abc/\".repath'  # Regex of full path\n        $ rh -e '\"*/ABC/*\".ipath' # Case-insensitive glob of full path\n        $ rh -e '\"/ABC/\".reipath' # Case-insensitive regex of full path\n\nFind symlinks by their target path (symlinks to anything under an `abc`\ndirectory):\n\n        $ rh -le '\"*/abc/*\".link'  # Glob of symlink target path\n        $ rh -le '\"/abc/\".relink'  # Regex of symlink target path\n        $ rh -le '\"*/ABC/*\".ilink' # Case-insensitive glob of symlink target\n        $ rh -le '\"/ABC/\".reilink' # Case-insensitive regex of symlink target\n\nFind files with *\"POSIX\"* ACLs (*Linux* and *Cygwin*) that grant write\naccess to the user `drew`:\n\n        $ rh -e '(uid == $drew) ? \"*user::?w?*\".acl   : \"*user:drew:?w?*\".acl'\n        $ rh -e '(uid == $drew) ? \"^user::.w.$\".reacl : \"^user:drew:.w.$\".reacl'\n\nFind files with *NFSv4* ACLs (*FreeBSD* and *Solaris*) that grant write\naccess to the user `drew`:\n\n        $ rh -e '(uid == $drew)\n            ?    \"*owner@:?w????????????:???????:allow*\".acl\n            : \"*user:drew:?w????????????:???????:allow*\".acl\n        '\n\n        $ rh -e '(uid == $drew)\n            ?    \"owner@:.w.{12}:.{7}:allow\".reacl\n            : \"user:drew:.w.{12}:.{7}:allow\".reacl\n        '\n\n        $ rh -e '(uid == $drew)\n            ?    \"owner@:[^:]+/write_data/[^:]+(:[^:]*)?:allow\".reacl\n            : \"user:drew:[^:]+/write_data/[^:]+(:[^:]*)?:allow\".reacl\n        '\n\nNote that, with *NFSv4* ACLs, you can search for ACLs using either the\ncompact form, or the non-compact form. But be warned that the permission\nnames in the non-compact form do not always appear in the same order (at\nleast on *Solaris*).\n\nFind files on *macOS* with ACLs that grant write access to the user `drew`:\n\n        $ rh -e '(uid == $drew) ? uw : \"user:[^:]+:drew:\\d+:allow:write\".reacl'\n\nFind files with non-trivial access control lists (ACL):\n\n        $ rh -e '\"*mask::*\".acl'        # \"POSIX\" ACLs (Linux, Cygwin)\n        $ rh -e '\"(user|group):\".reacl' # NFSv4 ACLs (FreeBSD, Solaris)\n        $ rh -e '\"?*\".acl'              # macOS ACLs\n\nFind files with extended attributes (EA):\n\n        $ rh -e '\"?*\".ea'\n        $ rh -e '\".\".reea'\n\nFind files on *Linux* by their *selinux(8)* context (any):\n\n        $ rh -e '\"*security.selinux: *_u:*_r:*_t:s[0-3]*\".ea'\n        $ rh -e '\"^security\\.selinux:\\ .*_u:.*_r:.*_t:s[0-3]\".reea'\n\nFind files on *Linux*, *FreeBSD*, *OpenBSD*, *NetBSD*, or *macOS*, that are\nimmutable or append-only:\n\n        $ rh -e 'immutable || append' /\n\nFind files on *Solaris* with setuid executable extended attributes (silly):\n\n        $ rh -e '\"*/stat: -rws*\".ea' /\n        $ rh -e '\"/stat:\\ -rws\".reea' /\n\n# DOCUMENTATION\n\n*Rawhide*'s documentation can be read here:\n\n- \u003chttps://raf.org/rawhide/manual/rh.1.html\u003e\n- \u003chttps://raf.org/rawhide/manual/rawhide.conf.5.html\u003e\n\n# DOWNLOAD\n\n*Rawhide*'s source distribution can be downloaded from these locations:\n\n- \u003chttps://raf.org/rawhide/download/rawhide-3.3.tar.gz\u003e (or [archive.org](https://web.archive.org/web/20230000000000*/https://raf.org/rawhide/download/rawhide-3.3.tar.gz))\n- \u003chttps://github.com/raforg/rawhide/releases/download/v3.3/rawhide-3.3.tar.gz\u003e\n\nThis is free software released under the terms of the GNU General Public\nLicence version 3 or later (*GPLv3+*).\n\n# INSTALL\n\nTo install *rawhide*:\n\n        tar xzf rawhide-3.3.tar.gz\n        cd rawhide-3.3\n        ./configure\n        make\n        make test # optional (lots of output, or set quiet=1)\n        sudo make install\n\nThis will install (approximately, depending on the operating system):\n\n        /etc/rawhide.conf\n        /etc/rawhide.conf.d/\n        /usr/local/bin/rh\n        /usr/local/share/man/man1/rh.1\n        /usr/local/share/man/man5/rawhide.conf.5\n\nTo uninstall *rawhide*:\n\n        sudo make uninstall\n\nTo install/uninstall under `/usr` instead of `/usr/local`:\n\n        sudo make PREFIX=/usr install\n        sudo make PREFIX=/usr uninstall\n\nTo check out the `configure` script which can override paths and features:\n\n        ./configure --help\n\nTo see what other things the `Makefile` can do:\n\n        make help\n\n# PACKAGING\n\nTo build a package on rpm-based *Linux* distributions:\n\n        rpmbuild -ta rawhide-3.3.tar.gz\n\n# REQUIREMENTS\n\n*Rawhide* should compile and work on any recent *POSIX* system (post-2008)\nwith a *C* compiler and *make*. It has been thoroughly tested on\n*Debian*/*Ubuntu*/*Fedora*/*Arch* *Linux*, *FreeBSD*, *OpenBSD*, *NetBSD*,\n*macOS*, *Solaris*, and *Cygwin*.\n\nThe *configure* script only knows about these systems as far as installation\nlocations are concerned, and whether or not manual entries should be\ngzipped. For other systems, you can accept the defaults, or override them\nwith the *configure* script's options, or manually adjust the *Makefile* to\nsuit your needs.\n\nThe (non-*POSIX*) *major()* and *minor()* macros are expected to be in\n`\u003csys/types.h\u003e`, `\u003csys/sysmacros.h\u003e`, or `\u003csys/mkdev.h\u003e`. If they are\nanywhere else, changes will be needed.\n\nWhile optional, it is very highly recommended that *libpcre2-8* be\ninstalled. It adds so much more fun. On *macOS*, *libpcre2-8* can be\ninstalled via *macports* or *homebrew*.\n\nIt is recommended that *libmagic* be installed. It lets search criteria\ninclude matching file type descriptions and MIME types. And *pkg-config* is\nneeded (to find and use it).\n\nOn *Linux*, *libacl* (for access control lists) and *libe2p* (for\n*ext2*-style file attributes) are also recommended. And *pkg-config* is\nneeded (to find and use them).\n\nTo build and install from the *git* repository, *pod2man* (which comes with\n*perl*) is needed to produce the manual entries. The source distribution\nincludes the installable manual entries (so *pod2man* isn't needed to build\nand install from the distribution).\n\n*Rawhide* only works completely in locales that use *UTF-8*. It mostly works\nin locales that use an *ASCII*-compatible single-byte character encoding\nsuch as *ISO-8859-\\** (except for *JSON* output). But other multi-byte\ncharacter encodings are not supported.\n\n--------------------------------------------------------------------------------\n\n    URL: https://raf.org/rawhide\n    GIT: https://github.com/raforg/rawhide\n    GIT: https://codeberg.org/raforg/rawhide\n    Date: 20231013\n    Authors: 1990 Ken Stauffer, 2022-2023 raf \u003craf@raf.org\u003e\n\n","funding_links":[],"categories":["Files and Directories","\u003ca name=\"find\"\u003e\u003c/a\u003eFile finding (alternatives to find)"],"sub_categories":["Search"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fraforg%2Frawhide","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fraforg%2Frawhide","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fraforg%2Frawhide/lists"}