git-remote rename: support branches->config migration
Get series with b4
b4 am [email protected]Versions newest first
- v2 Latest4 patches 3 repliesIn review
Patches in v2 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/4 | remote: add a new 'origin' variable to the structremote.c remote.h | +10 | 0 replies | |
| 1/4 | remote: add a new 'origin' variable to the structremote.c remote.h | +10 | 0 replies | |
| 2/4 | git-remote rename: support remotes->config migrationbuiltin-remote.c t/ | +54 | 0 replies | |
| 2/4 | git-remote rename: support remotes->config migrationbuiltin-remote.c t/ | +54 | 0 replies | |
| 3/4 | git-remote rename: support branches->config migrationbuiltin-remote.c t/ | +14 | 3 replies | |
| 3/4 | git-remote rename: support branches->config migrationbuiltin-remote.c t/ | +17 | 0 replies | |
| 4/4 | git-remote: document the migration feature of the rename subcommandDocumentation/ | +4 | 0 replies | |
| 4/4 | git-remote: document the migration feature of the rename subcommandDocumentation/ | +4 | 0 replies |
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v2 yet.
Cover letter [PATCH v2 0/4] git-remote rename: support branches->config migration
Quoted 8 lines · Junio C Hamano
The function
migrate_file()introduced by [2/4] is called for any remote definition that did not come from config (by definition, it either came from remotes/foo or branches/foo). The function adds the entries for the given remote definition to the config file, and then removes remotes/foo file if the remote definition came from it. So it is a logically consistent change if you only called this function only for remote definitions that came from remotes/foo.
Quoted 5 lines
But the function is called for a remote definition that originally came from branches/foo as well. It happily adds the definition to the config, even though it *fails to remove* branches/foo file.
Do you still think 2/4 is a logically contained good change?
OK, here is an updated series, which is supposed to fix this issue. 1/4 and 4/4 is unchanged.
Miklos Vajna (4):
remote: add a new 'origin' variable to the struct git-remote rename: support remotes->config migration git-remote rename: support branches->config migration
git-remote: document the migration feature of the rename subcommand
Documentation/git-remote.txt | 4 ++++ builtin-remote.c | 37 +++++++++++++++++++++++++++++++++++++ remote.c | 3 +++ remote.h | 7 +++++++ t/t5505-remote.sh | 33 +++++++++++++++++++++++++++++++++ 5 files changed, 84 insertions(+), 0 deletions(-)