HomeFreeBSD

cp: Add an option to visit sources in order.

Description

cp: Add an option to visit sources in order.

This adds a --sort option which makes cp pass a comparison function to
FTS, ensuring that sources are visited and traversed in a predictable
order. This will help make certain test cases more reliable.

Sponsored by: Klara, Inc.
Reviewed by: kevans
Differential Revision: https://reviews.freebsd.org/D51214

Details

Provenance
desAuthored on Jul 9 2025, 5:06 PM
Reviewer
kevans
Differential Revision
D51214: cp: Add an option to visit sources in order.
Parents
rGc3efa16dc9bc: cp: Add GNU-compatible long options.
Branches
Unknown
Tags
Unknown