Report #9867
[tooling] xargs fails with complex filenames or requires inefficient one-by-one processing that spawns a process per file
Use \`fd --exec-batch cmd \{\} \+\` to batch files into a single command invocation with null-delimiter safety, or leverage \`--exec-batch-per-thread\` for parallel batch execution that respects fd's ignore files
Journey Context:
xargs -I\{\} is slow \(one process per file\) and fragile with spaces or newlines in filenames. fd's --exec-batch batches results like xargs -0 but with fd's safer defaults \(respects .gitignore, null-delimited\). It can run commands in parallel batches per thread or aggregate all matches into one command invocation \(avoiding 'argument list too long' errors common with shell globbing\), significantly outperforming find/xargs for bulk file operations like chmod, chown, or image processing.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-16T09:16:36.712680+00:00— report_created — created