feat: recognize rsync old-dirs aliases
CI / lint (pull_request) Successful in 11s
CI / sanitizers (address) (pull_request) Successful in 38s
CI / sanitizers (undefined) (pull_request) Successful in 37s
CI / fuzz-build (pull_request) Successful in 16s
CI / coverage (pull_request) Successful in 32s
CI / build-and-test (pull_request) Successful in 1m16s
CI / valgrind (pull_request) Successful in 33s
CI / lint (pull_request) Successful in 11s
CI / sanitizers (address) (pull_request) Successful in 38s
CI / sanitizers (undefined) (pull_request) Successful in 37s
CI / fuzz-build (pull_request) Successful in 16s
CI / coverage (pull_request) Successful in 32s
CI / build-and-test (pull_request) Successful in 1m16s
CI / valgrind (pull_request) Successful in 33s
This commit is contained in:
@@ -125,6 +125,7 @@ typedef enum {
|
||||
OPT_POS_INT,
|
||||
OPT_NONNEG_INT,
|
||||
OPT_ULL,
|
||||
OPT_UNSUPPORTED,
|
||||
} OptKind;
|
||||
|
||||
typedef struct {
|
||||
@@ -153,6 +154,8 @@ static const OptionEntry OPTION_TABLE[] = {
|
||||
{"--sparse", "-S", OPT_FLAG, offsetof(Config, preserve_sparse)},
|
||||
{"--inplace", NULL, OPT_FLAG, offsetof(Config, inplace)},
|
||||
{"--checksum", NULL, OPT_FLAG, offsetof(Config, checksum)},
|
||||
{"--dirs", "--old-dirs", OPT_UNSUPPORTED, 0},
|
||||
{"--old-d", NULL, OPT_UNSUPPORTED, 0},
|
||||
|
||||
{"--source-dir", NULL, OPT_STRING, offsetof(Config, send_directory)},
|
||||
{"--dest-dir", NULL, OPT_STRING, offsetof(Config, receive_root_directory)},
|
||||
@@ -203,6 +206,11 @@ static int apply_table_option(Config* config, const OptionEntry* entry, const ch
|
||||
*(unsigned long long*)field = v;
|
||||
return 0;
|
||||
}
|
||||
case OPT_UNSUPPORTED:
|
||||
log_message(LOG_LEVEL_ERROR,
|
||||
"%s requires --dirs, which is not implemented; refusing to ignore option",
|
||||
entry->name);
|
||||
return -1;
|
||||
}
|
||||
return -1;
|
||||
}
|
||||
|
||||
@@ -21,6 +21,8 @@ void print_usage(void) {
|
||||
printf(" -p <port> SSH port (default: 22)\n");
|
||||
printf(" --progress Show transfer progress\n");
|
||||
printf(" --delete Delete files on receiver not in source\n");
|
||||
printf(
|
||||
" --dirs, --old-dirs, --old-d Transfer directories without recursing (not implemented)\n");
|
||||
printf(" --exclude <pattern> Exclude files matching pattern\n");
|
||||
printf(" --include <pattern> Only include files matching pattern\n");
|
||||
printf(" --exclude-from <file> Read exclude patterns from file\n");
|
||||
|
||||
Reference in New Issue
Block a user