Commit message (Collapse) | Author | Age | Files | Lines | ||
---|---|---|---|---|---|---|
... | ||||||
* | Implement -O. | Tavian Barnes | 2016-02-23 | 3 | -49/+85 | |
| | ||||||
* | Implement -D tree. | Tavian Barnes | 2016-02-23 | 2 | -209/+362 | |
| | ||||||
* | bftw: Update at_flags when not following a broken symbolic link. | Tavian Barnes | 2016-02-23 | 1 | -1/+2 | |
| | ||||||
* | bftw: Plug a leak when the root is not a directory. | Tavian Barnes | 2016-02-23 | 1 | -1/+6 | |
| | ||||||
* | Implement -D stat. | Tavian Barnes | 2016-02-22 | 3 | -1/+83 | |
| | ||||||
* | bftw: Use the currently open directory as at_fd in BFTW_CHILD mode. | Tavian Barnes | 2016-02-22 | 1 | -2/+5 | |
| | ||||||
* | Simplify double-negation. | Tavian Barnes | 2016-02-21 | 1 | -0/+5 | |
| | ||||||
* | bftw: Use O_CLOEXEC. | Tavian Barnes | 2016-02-21 | 1 | -3/+3 | |
| | ||||||
* | Make optimizations based on the purity of predicates. | Tavian Barnes | 2016-02-21 | 2 | -44/+42 | |
| | | | | | | | | This allows something like $ ./bfs -empty -false to avoid evaluating -empty, just like find. | |||||
* | Fix infinite recursion in eval_not(). | Tavian Barnes | 2016-02-21 | 1 | -6/+13 | |
| | | | | And use a helper function to prevent this kind of bug in the future. | |||||
* | bftw: Don't store the terminating '\0' in dircache_entry names. | Tavian Barnes | 2016-02-21 | 1 | -2/+1 | |
| | ||||||
* | bftw: Use a better cache eviction policy. | Tavian Barnes | 2016-02-21 | 1 | -113/+186 | |
| | | | | | | Instead of simple LRU, we now evict the open entry with the lowest refcount. This reduces the average number of components passed to openat() by a significant margin, and speeds bfs up by about ~5%. | |||||
* | bftw: Shrink the LRU before finding the parent. | Tavian Barnes | 2016-02-20 | 1 | -10/+6 | |
| | | | | Otherwise we might close the found parent. | |||||
* | bftw: Clean up dirqueue implementation a bit. | Tavian Barnes | 2016-02-19 | 1 | -20/+28 | |
| | ||||||
* | bftw: Don't keep DIR*'s around. | Tavian Barnes | 2016-02-19 | 1 | -40/+75 | |
| | | | | | | | | | | | | | | | DIR*'s were being kept around so dirfd(dir) could be passed to future openat() calls. But DIR*'s are big, holding a cache of filenames etc. read by readdir(). Instead, store the raw fd and dup() it to open a DIR* with fdopendir(). This way we can call dirclose() as soon as possible, while still keeping an open fd. Ideally there would be a way to closedir() without invoking close() on the underlying fd, but this is a good approximation. Reduces memory footprint by around 64% in a large directory tree. | |||||
* | -follow is a positional option. | Tavian Barnes | 2016-02-18 | 1 | -4/+4 | |
| | ||||||
* | bftw: Use a circular buffer to implement the dirqueue. | Tavian Barnes | 2016-02-17 | 1 | -46/+37 | |
| | ||||||
* | Fix an uninitialized value warning. | Tavian Barnes | 2016-02-17 | 1 | -2/+5 | |
| | ||||||
* | Initialize expr.cmp for -user and -group. | Tavian Barnes | 2016-02-17 | 1 | -0/+2 | |
| | ||||||
* | Add missing "error:" tag to error messages. | Tavian Barnes | 2016-02-16 | 1 | -2/+2 | |
| | ||||||
* | Makefile: Add install and uninstall targets. | Tavian Barnes | 2016-02-14 | 2 | -3/+38 | |
| | ||||||
* | Set the version to 0.67.0.67 | Tavian Barnes | 2016-02-14 | 2 | -3/+14 | |
| | | | | | For now, version numbers are the fraction of GNU find features supported. | |||||
* | Implement -user and -group. | Tavian Barnes | 2016-02-14 | 2 | -1/+100 | |
| | ||||||
* | s/color_table/colors/. | Tavian Barnes | 2016-02-14 | 4 | -19/+19 | |
| | ||||||
* | Refactor color handling. | Tavian Barnes | 2016-02-14 | 5 | -65/+122 | |
| | | | | The main benefit is colored warnings/errors during parsing. | |||||
* | Don't modify the result of getenv(). | Tavian Barnes | 2016-02-14 | 2 | -4/+11 | |
| | ||||||
* | Implement -lname and -ilname. | Tavian Barnes | 2016-02-14 | 4 | -2/+67 | |
| | ||||||
* | "Implement" -noleaf. | Tavian Barnes | 2016-02-14 | 1 | -0/+15 | |
| | ||||||
* | Implement -mount/-xdev. | Tavian Barnes | 2016-02-14 | 3 | -3/+20 | |
| | ||||||
* | Add brief -help and -version support. | Tavian Barnes | 2016-02-14 | 3 | -2/+66 | |
| | ||||||
* | Don't stop early just because deleting failed. | Tavian Barnes | 2016-02-14 | 1 | -1/+1 | |
| | ||||||
* | Implement -iname and -ipath. | Tavian Barnes | 2016-02-13 | 4 | -10/+59 | |
| | ||||||
* | Fix -name handling when the root has trailing slashes. | Tavian Barnes | 2016-02-13 | 3 | -4/+60 | |
| | ||||||
* | Implement -xtype. | Tavian Barnes | 2016-02-13 | 4 | -6/+76 | |
| | ||||||
* | Follow links if appropriate in predicates. | Tavian Barnes | 2016-02-13 | 3 | -7/+7 | |
| | ||||||
* | More s/cl/cmdline/. | Tavian Barnes | 2016-02-13 | 2 | -49/+49 | |
| | ||||||
* | tests.sh: Don't re-create the same directory structures needlessly. | Tavian Barnes | 2016-02-13 | 1 | -69/+56 | |
| | ||||||
* | Check the number of open FDs at the start. | Tavian Barnes | 2016-02-12 | 1 | -22/+42 | |
| | | | | | | This fixes the issues with things like $ bfs -empty 3</dev/null | |||||
* | Consolidate some error reporting logic. | Tavian Barnes | 2016-02-12 | 1 | -7/+12 | |
| | ||||||
* | Use 'cmdline' instead of 'cl'. | Tavian Barnes | 2016-02-12 | 2 | -19/+19 | |
| | ||||||
* | Report failures that happen inside predicates. | Tavian Barnes | 2016-02-12 | 2 | -7/+30 | |
| | ||||||
* | Keep one fd free for the predicates themselves. | Tavian Barnes | 2016-02-11 | 1 | -3/+3 | |
| | | | | | | | | | | | | Otherwise -empty may start failing once the dircache grows. It's still possible to cause failures with $ bfs some/big/dir -empty 3</dev/null because one more fd than expected will be allocated, but that's not a common case. It could be worked around by reading /proc/self/fd/ at startup. | |||||
* | Implement -samefile. | Tavian Barnes | 2016-02-10 | 4 | -8/+66 | |
| | ||||||
* | Add a README. | Tavian Barnes | 2016-02-10 | 1 | -0/+93 | |
| | ||||||
* | Implement -L/-follow. | Tavian Barnes | 2016-02-09 | 4 | -34/+110 | |
| | ||||||
* | bftw: Don't give up when following a broken symlink. | Tavian Barnes | 2016-02-06 | 2 | -2/+16 | |
| | ||||||
* | Implement -P and -H. | Tavian Barnes | 2016-02-04 | 4 | -9/+57 | |
| | ||||||
* | Drive the literal parsing with a switch. | Tavian Barnes | 2016-02-04 | 1 | -82/+157 | |
| | ||||||
* | Implement -links. | Tavian Barnes | 2016-02-04 | 4 | -1/+32 | |
| | ||||||
* | Implement -inum. | Tavian Barnes | 2016-02-04 | 3 | -0/+15 | |
| |