summaryrefslogtreecommitdiffstats
path: root/src/ctx.h
Commit message (Collapse)AuthorAgeFilesLines
* expr: Get rid of the extra list nodeTavian Barnes2024-11-041-3/+1
| | | | We can now just use for_arena() to iterate over the allocated bfs_exprs.
* Write @arg instead of @param arg in doc commentsTavian Barnes2024-10-011-8/+8
|
* build: Move feature test macros to prelude.hTavian Barnes2024-08-281-2/+0
| | | | | | This replaces the explicit CPPFLAGS list in flags.mk with just `-include src/prelude.h`, shortening our compiler command lines and allowing them to be easily documented.
* prelude: Split bfs-specific utilities into new bfs.h headerTavian Barnes2024-08-281-0/+2
|
* New -noerror option to suppress error messagesTavian Barnes2024-08-161-0/+2
| | | | Closes: https://github.com/tavianator/bfs/issues/142
* opt: Warn about ignored expressions after dangerous actionsTavian Barnes2024-08-121-2/+7
| | | | | | For example, `bfs -delete -type f` is almost certainly a mistake. Link: https://savannah.gnu.org/bugs/?65895
* parse: Take umask into account in parse_mode()Tavian Barnes2024-08-021-0/+4
| | | | | | | POSIX 2024 clarified that find(1) is meant to work exactly like chmod(1) here, so for modes like +rw,-x with no "who" specified, apply the umask. Link: https://www.austingroupbugs.net/view.php?id=1392
* opt: Don't raise RLIMIT_NOFILE if it would prevent using posix_spawn()Tavian Barnes2024-05-231-0/+2
| | | | | | | | | | If we raise RLIMIT_NOFILE, we have to lower it before calling exec() for compatibility with select(). If posix_spawn() doesn't support that, we fall back to fork(), which is quite a bit slower. Therefore, if we're going to exec() on most files, it's better to keep RLIMIT_NOFILE the same to avoid the fork() cost, even though it makes bftw() somewhat slower.
* Rename config.h to prelude.hTavian Barnes2024-04-191-1/+1
|
* Re-run include-what-you-useTavian Barnes2024-03-111-0/+2
|
* expr: Arena-allocate expressionsTavian Barnes2023-12-201-0/+6
|
* ctx: Switch paths from darray to RESERVE()Tavian Barnes2023-11-231-0/+3
|
* ctx: Store the original and current RLIMIT_NOFILETavian Barnes2023-11-061-4/+4
|
* diag: Move enum debug_flags out of ctx.hTavian Barnes2023-10-121-27/+1
|
* bftw: Use an I/O queue to open directoriesTavian Barnes2023-06-131-0/+2
| | | | Parallelism is controlled by the new -j flag.
* config: Provide <stdalign.h> and <stdbool.h>Tavian Barnes2023-05-111-1/+1
| | | | In anticipation of C23, since those headers won't be necessary any more.
* Replace license boilerplate with SPDX tagsTavian Barnes2023-01-251-15/+2
| | | | | | | And while I'm at it, remove years from copyright declarations. Link: https://spdx.dev/about/ Link: https://daniel.haxx.se/blog/2023/01/08/copyright-without-years/
* expr: Don't use reftime for -lsTavian Barnes2022-11-171-0/+4
| | | | | reftime is part of a different union than the print actions are supposed to use.
* pwcache: Fill the user/group caches lazilyTavian Barnes2022-11-091-23/+1
| | | | | | | Iterating all the users/groups can be expensive, especially with NSS. Android has so many that it doesn't even return them all from get{pw,gr}ent() for performance reasons, leading to incorrect behaviour of -user/-group/etc.
* Fix includesTavian Barnes2022-11-061-0/+1
|
* Source / Include Folder (#88)トトも2022-04-161-0/+212
Moved Source Files Into `src` Folder