Repository navigation
fix: wire --ignore-existing, --existing, --max-delete into server path - #2573
Merged
Merged
Conversation
These three flags were already sent by the client (SSH and daemon) and handled in the local-copy engine, but the server-side never parsed or applied them. This caused the flags to be silently ignored during remote transfers. Changes: - Add ignore_existing, existing_only, max_delete fields to ServerConfig - Parse --ignore-existing, --existing/--ignore-non-existing, and --max-delete=NUM in server long-flag parsing (server.rs) - Register all three in is_known_server_long_flag() so they don't interfere with compact flag string discovery - Wire ignore_existing and existing_only into build_files_to_transfer() receiver filtering, integrated with the parallel stat phase - Refactor quick_check_ok_stateless() into quick_check_matches() that takes pre-fetched metadata, enabling a single stat() call to serve both existence checks and quick-check comparison Upstream references: - generator.c:1562 — ignore_existing skip when file exists - generator.c:1571 — existing_only skip when file absent - options.c:2823 — --max-delete=NUM in server_options()
oferchen
added a commit
that referenced
this pull request
May 1, 2026
#2573) These three flags were already sent by the client (SSH and daemon) and handled in the local-copy engine, but the server-side never parsed or applied them. This caused the flags to be silently ignored during remote transfers. Changes: - Add ignore_existing, existing_only, max_delete fields to ServerConfig - Parse --ignore-existing, --existing/--ignore-non-existing, and --max-delete=NUM in server long-flag parsing (server.rs) - Register all three in is_known_server_long_flag() so they don't interfere with compact flag string discovery - Wire ignore_existing and existing_only into build_files_to_transfer() receiver filtering, integrated with the parallel stat phase - Refactor quick_check_ok_stateless() into quick_check_matches() that takes pre-fetched metadata, enabling a single stat() call to serve both existence checks and quick-check comparison Upstream references: - generator.c:1562 — ignore_existing skip when file exists - generator.c:1571 — existing_only skip when file absent - options.c:2823 — --max-delete=NUM in server_options()
oferchen
added a commit
that referenced
this pull request
May 5, 2026
#2573) These three flags were already sent by the client (SSH and daemon) and handled in the local-copy engine, but the server-side never parsed or applied them. This caused the flags to be silently ignored during remote transfers. Changes: - Add ignore_existing, existing_only, max_delete fields to ServerConfig - Parse --ignore-existing, --existing/--ignore-non-existing, and --max-delete=NUM in server long-flag parsing (server.rs) - Register all three in is_known_server_long_flag() so they don't interfere with compact flag string discovery - Wire ignore_existing and existing_only into build_files_to_transfer() receiver filtering, integrated with the parallel stat phase - Refactor quick_check_ok_stateless() into quick_check_matches() that takes pre-fetched metadata, enabling a single stat() call to serve both existence checks and quick-check comparison Upstream references: - generator.c:1562 — ignore_existing skip when file exists - generator.c:1571 — existing_only skip when file absent - options.c:2823 — --max-delete=NUM in server_options()
1 of 2 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
--ignore-existing,--existing/--ignore-non-existing, and--max-delete=NUMinto the server-side parsing and receiver filtering for remote (SSH/daemon) transfersignore_existing,existing_only,max_deletefields toServerConfigparse_server_long_flags()and register inis_known_server_long_flag()ignore_existingandexisting_onlyfiltering intobuild_files_to_transfer()parallel stat phasequick_check_ok_stateless()intoquick_check_matches()- takes pre-fetched metadata to avoid redundant stat callsUpstream references
generator.c:1562-ignore_existingskip when file existsgenerator.c:1571-existing_onlyskip when file absentoptions.c:2823---max-delete=NUMinserver_options()Test plan
cargo fmt --all -- --checkpassescargo clippy -p transfer -p cli --all-targets --all-features --no-deps -- -D warningspassescargo nextest run -p transfer --all-features -E 'test(negotiated)'- 23 tests pass