commit 459c9b5d729663985a65eb88b5bb8955ca336251 from: Stefan Sperling via: Thomas Adam date: Sun Jul 03 22:08:19 2022 UTC rename got.conf(5) mirror-references to mirror_references for consistency Existing configuration files will keep working for now since the old name with dashes is still recognized by the config parser. commit - 25eb584767361afbce3002356d91ff8d0a2a0ec0 commit + 459c9b5d729663985a65eb88b5bb8955ca336251 blob - f01cac5dc50969a9494f5e5bacbbc3294dcd7e66 blob + 06178d049f6e1c1b3ca9e8e1ff2b0fd4b578c310 --- got/got.c +++ got/got.c @@ -1343,7 +1343,7 @@ create_gotconfig(const char *proto, const char *host, remote_repo_path, branches ? "\tbranch { " : "", branches ? branches : "", branches ? "}\n" : "", refs ? "\treference { " : "", refs ? refs : "", refs ? "}\n" : "", - mirror_references ? "\tmirror-references yes\n" : "", + mirror_references ? "\tmirror_references yes\n" : "", fetch_all_branches ? "\tfetch_all_branches yes\n" : "") == -1) { err = got_error_from_errno("asprintf"); goto done; blob - d529aa621ed42968bf9ec5a26a20886121bb26b9 blob + 5827c264f952cb78e122d0a899886cfbedf1aab2 --- got/got.conf.5 +++ got/got.conf.5 @@ -151,7 +151,7 @@ In any case, references in the .Dq refs/tags/ namespace will always be fetched and mapped directly to local references in the same namespace. -.It Ic mirror-references Ar yes | no +.It Ic mirror_references Ar yes | no This option controls the behaviour of .Cm got fetch when updating references. @@ -239,7 +239,7 @@ remote "origin" { repository "openbsd/src" server git@github.com protocol git+ssh - mirror-references yes + mirror_references yes } .Ed .Pp blob - 678ad4bb419a9b27359fa472a99aabea8305be37 blob + 4887063efbdcb153fdda2c449c0904563fa308ae --- libexec/got-read-gotconfig/parse.y +++ libexec/got-read-gotconfig/parse.y @@ -375,7 +375,8 @@ lookup(char *s) {"fetch", FETCH}, {"fetch-all-branches", FETCH_ALL_BRANCHES}, /* deprecated */ {"fetch_all_branches", FETCH_ALL_BRANCHES}, - {"mirror-references", MIRROR_REFERENCES}, + {"mirror-references", MIRROR_REFERENCES}, /* deprecated */ + {"mirror_references", MIRROR_REFERENCES}, {"port", PORT}, {"protocol", PROTOCOL}, {"reference", REFERENCE}, blob - 192edf26e55801998924e5735bd4c73a5c1a336c blob + 35d7c0ba41e646078b5beea834a05d4d28891363 --- regress/cmdline/clone.sh +++ regress/cmdline/clone.sh @@ -349,7 +349,7 @@ remote "origin" { protocol ssh repository "$testroot/repo" branch { "master" } - mirror-references yes + mirror_references yes } EOF cmp -s $testroot/repo-clone/got.conf $testroot/got.conf.expected @@ -421,7 +421,7 @@ remote "origin" { server 127.0.0.1 protocol ssh repository "$testroot/repo" - mirror-references yes + mirror_references yes fetch_all_branches yes } EOF @@ -649,7 +649,7 @@ remote "origin" { repository "$testroot/repo" branch { "master" } reference { "hoo" } - mirror-references yes + mirror_references yes } EOF cmp -s $testroot/repo-clone/got.conf $testroot/got.conf.expected