Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | tests: Use xtouch to create the whole deep tree at once | Tavian Barnes | 2023-10-20 | 1 | -15/+6 |
| | |||||
* | tests/xtouch: Recover from ENAMETOOLONG | Tavian Barnes | 2023-10-20 | 1 | -45/+84 |
| | |||||
* | tests: Don't unset array[-1] | Tavian Barnes | 2023-10-19 | 1 | -6/+7 |
| | | | | This was only added in Bash 4.3 which is too new for macOS. | ||||
* | tests: Refactor implementation into separate files | Tavian Barnes | 2023-10-19 | 13 | -823/+906 |
| | |||||
* | tests: Update bash coding style | Tavian Barnes | 2023-10-19 | 1 | -32/+32 |
| | |||||
* | tests: Clean up colorization | Tavian Barnes | 2023-10-19 | 1 | -76/+102 |
| | |||||
* | tests: Use the ERR trap to print the failing command | Tavian Barnes | 2023-10-19 | 1 | -4/+46 |
| | |||||
* | tests: Fix uses of $? with set -e | Tavian Barnes | 2023-10-19 | 1 | -10/+12 |
| | |||||
* | tests: New defer function | Tavian Barnes | 2023-10-19 | 18 | -34/+54 |
| | |||||
* | tests: Rename --noclean -> --no-clean | Tavian Barnes | 2023-10-19 | 1 | -3/+3 |
| | |||||
* | parse: Set BFTW_WHITEOUTS when parsing -type w | Tavian Barnes | 2023-10-17 | 2 | -0/+102 |
| | |||||
* | dir: Fix FreeBSD union mounts | Tavian Barnes | 2023-10-17 | 4 | -0/+28 |
| | |||||
* | tests: Move closed_std* tests out of the POSIX group | Tavian Barnes | 2023-10-14 | 6 | -2/+8 |
| | | | | | | | | | | | | | POSIX actually says > If the utility would be executed with file descriptor 0, 1, or 2 > closed, implementations may execute the utility with the file > descriptor open to an unspecified file. So we're not guaranteed to be able to detect the situation in the first place. Add a best-effort check for these platforms and skip the test. Link: https://pubs.opengroup.org/onlinepubs/9699919799/utilities/V3_chap02.html#tag_18_09_01_01 | ||||
* | tests: Always create the scratch directory | Tavian Barnes | 2023-10-13 | 1 | -0/+2 |
| | | | | | | | | | | | | | | | | Otherwise, some tests that try to check for flag support like invoke_bfs scratch -quit -xattr || skip can be accidentally skipped if ./scratch doesn't exist yet: $ ./tests/tests.sh bsd/xattr tests skipped: 1 After this patch, we get the expected $ ./tests/tests.sh bsd/xattr tests passed: 1 | ||||
* | tests: Don't crash if unbuffer isn't installed | Tavian Barnes | 2023-10-12 | 1 | -1/+1 |
| | |||||
* | diag: Move enum debug_flags out of ctx.h | Tavian Barnes | 2023-10-12 | 1 | -0/+1 |
| | |||||
* | alloc: Test allocation size overflows | Tavian Barnes | 2023-10-06 | 1 | -2/+10 |
| | |||||
* | tests/bfs/status: Try to test SIGWINCH | Tavian Barnes | 2023-10-06 | 1 | -1/+1 |
| | |||||
* | tests: Check for expect_unbuffer too | Tavian Barnes | 2023-10-06 | 1 | -2/+8 |
| | | | | That's where FreeBSD installs it. | ||||
* | tests: New bfs_pty wrapper for unbuffer | Tavian Barnes | 2023-10-06 | 4 | -7/+17 |
| | |||||
* | tests/bfs: Add a test that runs -status | Tavian Barnes | 2023-10-05 | 1 | -0/+3 |
| | |||||
* | tests/bfs: Add tests for color autodetection | Tavian Barnes | 2023-10-05 | 4 | -0/+65 |
| | |||||
* | tests: Respect $NO_COLOR | Tavian Barnes | 2023-10-05 | 1 | -9/+15 |
| | |||||
* | bfstd: Add a thread-safe wrapper for strerror() | Tavian Barnes | 2023-10-05 | 3 | -6/+6 |
| | |||||
* | tests: Fix make_deep() on FreeBSD | Tavian Barnes | 2023-10-02 | 1 | -9/+10 |
| | | | | I keep forgetting that PATH_MAX is only 1024 there. | ||||
* | Merge branch 'benchmarks' | Tavian Barnes | 2023-10-02 | 1 | -15/+24 |
|\ | |||||
| * | tests/xtouch: Try creating the immediate parent first | Tavian Barnes | 2023-09-29 | 1 | -15/+24 |
| | | |||||
* | | tests: Don't cd into paths longer than PATH_MAX | Tavian Barnes | 2023-10-02 | 1 | -12/+8 |
|/ | | | | | | This fixes a warning on at least Alpine Linux that looks like cd: error retrieving current directory: getcwd: cannot access parent directories: Filename too long | ||||
* | Formatting fixes | Tavian Barnes | 2023-09-27 | 4 | -7/+7 |
| | |||||
* | Use the new list macros | Tavian Barnes | 2023-09-25 | 1 | -2/+2 |
| | |||||
* | bfstd: Fix printable_len() off-by-one | Tavian Barnes | 2023-09-06 | 1 | -0/+15 |
| | | | | | | | If xmbrtowc() fails, or if xiswprint() is false, then we shouldn't include that wide char in the printable length. Fixes: 19c96abe0a1ee56cf206fd5e87defb1fd3e0daa5 | ||||
* | bfstd: Fix an OOB string index in xmbrtowc() | Tavian Barnes | 2023-09-06 | 2 | -0/+22 |
| | | | | | | | | | | | | | | | | | | | | | | This bug could be reproduced with something like $ bfs -samefile $'\xFA\xFA' bfs: error: bfs: dstrnescat@src/dstring.c:252: wordesc() result truncated or worse, with -DNDEBUG, $ bfs -samefile $'.....................\xFA\xFA' bfs: error: bfs -samefile $'.....................\xFA\xFA\x00\x55\x53\x45\x52\x3D\x74\x61\x76\x69\x61\x6E\x61\x74\x6F\x72 bfs: error: ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ bfs: error: No such file or directory. which prints the memory after the end of the string (in this case, the environment variable USER=tavianator). The bug was caused by the line `*i += len`, which was intended to be `*i = len`. But actually, the right behaviour seems to be `*i += 1`. Fixes: 19c96abe0a1ee56cf206fd5e87defb1fd3e0daa5 | ||||
* | Work around https://github.com/llvm/llvm-project/issues/64946 | Tavian Barnes | 2023-08-23 | 1 | -0/+3 |
| | |||||
* | tests: Add missing .out file | Tavian Barnes | 2023-08-14 | 1 | -0/+0 |
| | |||||
* | parse: Allow -files0-from an empty set of paths | Tavian Barnes | 2023-08-14 | 1 | -1/+1 |
| | | | | This follows a behaviour change in GNU findutils 4.9.0. | ||||
* | color: Only highlight the trailing slash on ENOTDIR | Tavian Barnes | 2023-07-13 | 2 | -5/+5 |
| | |||||
* | color: Don't break up leading and trailing dirs | Tavian Barnes | 2023-07-13 | 39 | -61/+63 |
| | |||||
* | color: TTY-escape filenames | Tavian Barnes | 2023-07-13 | 40 | -0/+78 |
| | |||||
* | color: Get rid of EXT_MAX | Tavian Barnes | 2023-07-13 | 2 | -0/+23 |
| | |||||
* | parse: Reject -j0 | Tavian Barnes | 2023-07-12 | 1 | -0/+1 |
| | |||||
* | tests/bfs: Add tests for -j | Tavian Barnes | 2023-07-12 | 5 | -0/+41 |
| | |||||
* | color: Compare values too when deciding to smart-case | Tavian Barnes | 2023-06-30 | 2 | -2/+7 |
| | |||||
* | color: Implement smart casing | Tavian Barnes | 2023-06-29 | 5 | -10/+12 |
| | | | | | | | | | Since coreutils 9.2, ls does case-sensitive extension matching if the same extension is capitalized differently in $LS_COLORS. Implement the same logic. Link: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=33123 Link: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=9086 | ||||
* | tests/bfs/color: Add mixed-case extensions | Tavian Barnes | 2023-06-29 | 40 | -118/+315 |
| | |||||
* | tests: Get more tests passing with --bfs=tests/find-color.sh | Tavian Barnes | 2023-06-27 | 1 | -5/+32 |
| | |||||
* | tests/gnu/printf_times: Correct %T@ to %A@ | Tavian Barnes | 2023-06-22 | 1 | -1/+1 |
| | |||||
* | alloc: Implement an arena for flexible structs | Tavian Barnes | 2023-06-20 | 1 | -1/+13 |
| | |||||
* | alloc: New header for memory allocation utilities | Tavian Barnes | 2023-06-20 | 2 | -11/+26 |
| | |||||
* | color: `fi=0` should not fall back to `no` | Tavian Barnes | 2023-06-08 | 8 | -0/+84 |
| | |||||
* | tests/bfstd: Use bfs_verify() over explicit abort() | Tavian Barnes | 2023-05-19 | 1 | -14/+5 |
| |