| 1018 | } |
| 1019 | |
| 1020 | static int move_config_setting(const char *key, const char *value, |
| 1021 | const char *from_file, const char *to_file) |
| 1022 | { |
| 1023 | if (repo_config_set_in_file_gently(the_repository, to_file, key, NULL, value)) |
| 1024 | return error(_("unable to set %s in '%s'"), key, to_file); |
| 1025 | if (repo_config_set_in_file_gently(the_repository, from_file, key, NULL, NULL)) |
| 1026 | return error(_("unable to unset %s in '%s'"), key, from_file); |
| 1027 | return 0; |
| 1028 | } |
| 1029 | |
| 1030 | int init_worktree_config(struct repository *r) |
| 1031 | { |
no test coverage detected