Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | bftw: Recover from ENAMETOOLONG | Tavian Barnes | 2017-07-08 | 1 | -0/+30 |
| | | | | | | | | | | | | | | | | | | | | | | | | It is always possible to force a breadth-first traversal to encounter ENAMETOOLONG, regardless of the dircache eviction policy. As a concrete example, consider this directory structure: ./1/{NAME_MAX}/{NAME_MAX}/{NAME_MAX}/... (longer than {PATH_MAX}) ./2/{NAME_MAX}/{NAME_MAX}/{NAME_MAX}/... ./3/{NAME_MAX}/{NAME_MAX}/{NAME_MAX}/... ... (more than RLIMIT_NOFILE directories under .) Eventually, the next file to be processed will not have any parents in the cache, as the cache can only hold RLIMIT_NOFILE entries. Then the whole path must be traversed from ., which will exceed {PATH_MAX} bytes. Work around this by performing a component-by-component traversal manually when we see ENAMETOOLONG. This is required by POSIX: > The find utility shall be able to descend to arbitrary depths in a file > hierarchy and shall not fail due to path length limitations (unless a > path operand specified by the application exceeds {PATH_MAX} > requirements). | ||||
* | -perm: Handle permcopy (e.g. u=rw,g=u) correctly | Tavian Barnes | 2017-06-15 | 1 | -0/+5 |
| | |||||
* | tests: Fix test_printf_nul with non-GNU sort | Tavian Barnes | 2017-06-11 | 1 | -1/+7 |
| | | | | | Other UNIX sort implementations seem to truncate at the nul bytes, so open-code it without the sort. | ||||
* | printf: Fix embedded nul bytes | Tavian Barnes | 2017-06-10 | 1 | -0/+6 |
| | | | | Fixes #26. | ||||
* | Don't make -quit disable the implicit -print | Tavian Barnes | 2017-05-11 | 1 | -2/+7 |
| | |||||
* | Release 1.01.0 | Tavian Barnes | 2017-04-24 | 1 | -0/+11 |
| | |||||
* | Implement -fstype | Tavian Barnes | 2017-04-23 | 1 | -0/+6 |
| | | | | Fixes #6! | ||||
* | tests.sh: Allow individual tests to be specified on the command line | Tavian Barnes | 2017-04-16 | 1 | -10/+16 |
| | |||||
* | Implement -X | Tavian Barnes | 2017-04-16 | 1 | -0/+7 |
| | |||||
* | tests: Add tests for bfs extensions to -exec ... + | Tavian Barnes | 2017-04-16 | 1 | -0/+10 |
| | |||||
* | Implement -exec/-execdir ... + | Tavian Barnes | 2017-04-15 | 1 | -0/+10 |
| | |||||
* | tests.sh: Use eval instead of declare -g | Tavian Barnes | 2017-04-08 | 1 | -1/+1 |
| | | | | Turns out declare -g is from Bash 4 too. | ||||
* | tests: Run everything in UTC | Tavian Barnes | 2017-03-11 | 1 | -1/+2 |
| | |||||
* | Add a test for colored output | Tavian Barnes | 2017-03-11 | 1 | -0/+5 |
| | |||||
* | Implement -printf %Ak, %Ck, and %Tk | Tavian Barnes | 2017-03-11 | 1 | -1/+6 |
| | |||||
* | tests: Print the count of passing and failing tests | Tavian Barnes | 2017-02-11 | 1 | -13/+14 |
| | |||||
* | Add some tests for the operators themselves | Tavian Barnes | 2017-02-11 | 1 | -10/+50 |
| | |||||
* | Add tests for bfs's flexible command line parsing | Tavian Barnes | 2017-02-10 | 1 | -0/+25 |
| | |||||
* | tests: Don't require bash associative arrays | Tavian Barnes | 2017-02-10 | 1 | -22/+11 |
| | | | | That's a bash 4 feature, while macOS is stuck on bash 3. | ||||
* | bftw: Make the nameoff of "///" point to "/" | Tavian Barnes | 2017-02-09 | 1 | -1/+2 |
| | | | | This simplifies a few things such as -name handling for ///. | ||||
* | Give the test cases human-readable names | Tavian Barnes | 2017-02-09 | 1 | -312/+433 |
| | |||||
* | Don't close stdin for -ok or -okdir | Tavian Barnes | 2017-02-09 | 1 | -6/+7 |
| | | | | Turns out it violates POSIX, even though GNU find does it. | ||||
* | Add support for -x?type with multiple types | Tavian Barnes | 2017-02-08 | 1 | -1/+11 |
| | | | | This functionality is already part of GNU findutils git. | ||||
* | Fix a memory leak parsing -printf | Tavian Barnes | 2017-02-06 | 1 | -1/+7 |
| | |||||
* | tests.sh: Set the umask before creating the test trees | Tavian Barnes | 2017-02-06 | 1 | -0/+1 |
| | |||||
* | Make -quit happen immediately, not at the end of the current expression | Tavian Barnes | 2017-02-05 | 1 | -1/+11 |
| | |||||
* | bftw: Compute nameoff correctly for the root in BFTW_DEPTH mode | Tavian Barnes | 2017-02-05 | 1 | -1/+5 |
| | |||||
* | Implement -printf/-fprintf | Tavian Barnes | 2017-02-05 | 1 | -9/+42 |
| | | | | | Based on a patch by Fangrui Song <i@maskray.me>. Closes #16. | ||||
* | Implement -nouser and -nogroup | Tavian Barnes | 2017-02-04 | 1 | -1/+18 |
| | |||||
* | tests: Add a test for -inum | Tavian Barnes | 2017-01-03 | 1 | -1/+8 |
| | |||||
* | tests: Add tests for -quit | Tavian Barnes | 2017-01-02 | 1 | -1/+21 |
| | |||||
* | Set _FILE_OFFSET_BITS to 64 | Tavian Barnes | 2016-12-21 | 1 | -1/+6 |
| | | | | | With the new support for -size n[TP], this is needed to avoid overflow on 32-bit platforms. | ||||
* | Implement -mnewer | Tavian Barnes | 2016-12-20 | 1 | -1/+11 |
| | |||||
* | Support -[gu]id NAME like BSD find | Tavian Barnes | 2016-12-20 | 1 | -1/+11 |
| | |||||
* | Implement BSD find's -depth N | Tavian Barnes | 2016-12-18 | 1 | -1/+31 |
| | |||||
* | tests: Allow limiting the testsuite to POSIX, BSD, GNU, and bfs-specific ↵ | Tavian Barnes | 2016-12-18 | 1 | -11/+128 |
| | | | | features | ||||
* | tests.sh: Let the bfs binary be specified on the command line | Tavian Barnes | 2016-12-18 | 1 | -21/+35 |
| | |||||
* | Implement -regex, -iregex, and -regextype/-E | Tavian Barnes | 2016-12-18 | 1 | -1/+29 |
| | |||||
* | tests: Fix failure when /tmp is a symlink. | Tavian Barnes | 2016-12-08 | 1 | -1/+4 |
| | |||||
* | tests: Don't use install -D | Tavian Barnes | 2016-12-08 | 1 | -7/+14 |
| | | | | -D is a GNU-ism that doesn't work on BSD or macOS. | ||||
* | tests: Don't check -size for directories | Tavian Barnes | 2016-12-05 | 1 | -3/+4 |
| | |||||
* | tests: Don't check -links for directories | Tavian Barnes | 2016-12-05 | 1 | -3/+3 |
| | |||||
* | Allow // to be different from / | Tavian Barnes | 2016-11-24 | 1 | -3/+2 |
| | | | | | | POSIX says that // may be resolved in an implementation-defined way (generally, to access network shares). So don't use it in tests, and don't canonicalize it to '/' in -execdir. | ||||
* | tests: Make sure the temporary directory is owned by the current user/group | Tavian Barnes | 2016-11-22 | 1 | -0/+1 |
| | | | | | BSDs apparently prefer to create new files/directories with the same group as the parent directory, rather than the current primary group. | ||||
* | tests: Mkae LC_ALL=C apply to the whole pipeline when sorting. | Tavian Barnes | 2016-11-22 | 1 | -1/+4 |
| | |||||
* | Support -perm +MODE for symbolic modes. | Tavian Barnes | 2016-11-21 | 1 | -1/+1 |
| | | | | Only things like -perm +777 are disallowed by GNU find. | ||||
* | Fix -execdir for / | Tavian Barnes | 2016-11-21 | 1 | -1/+15 |
| | |||||
* | tests: Don't rely on the system 'find' for the expected output. | Tavian Barnes | 2016-11-21 | 1 | -142/+211 |
| | |||||
* | Don't try to -delete the current directory. | Tavian Barnes | 2016-11-13 | 1 | -1/+6 |
| | |||||
* | bftw: Keep trailing slashes on the root in BFTW_DEPTH mode. | Tavian Barnes | 2016-11-13 | 1 | -1/+5 |
| |