Skip to content

Commit 48aa97b

Browse files
matttproudgopherbot
authored andcommitted
git-codereview: frame sync as git codereview sync
The codereview binary referred to the sync subcommand as merely "git sync" in a number of places in user surfaces. This was wrong and misleading, so the code now refers to it with the codereview parent subcommand in the name (i.e., a "git codereview sync"). Change-Id: Icf3f96a8c76b57319bc3101b3e9fd0cbd8cecea9 Reviewed-on: https://go-review.googlesource.com/c/review/+/685855 Auto-Submit: Sean Liao <[email protected]> LUCI-TryBot-Result: Go LUCI <[email protected]> Reviewed-by: Carlos Amedee <[email protected]> Reviewed-by: Sean Liao <[email protected]> Reviewed-by: David Chase <[email protected]>
1 parent c4af2b0 commit 48aa97b

File tree

4 files changed

+7
-7
lines changed

4 files changed

+7
-7
lines changed

git-codereview/change.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -184,10 +184,10 @@ func checkoutOrCreate(target string) {
184184
origin := b.OriginBranch()
185185

186186
// NOTE: This is different from git checkout -q -t -b origin,
187-
// because the -t wold use the origin directly, and that may be
187+
// because the -t would use the origin directly, and that may be
188188
// ahead of the current directory. The goal of this command is
189189
// to create a new branch for work on the current directory,
190-
// not to incorporate new commits at the same time (use 'git sync' for that).
190+
// not to incorporate new commits at the same time (use 'git codereview sync' for that).
191191
// The ideal is that HEAD doesn't change at all.
192192
// In the absence of pending commits, that ideal is achieved.
193193
// But if there are pending commits, it'd be too confusing to have them

git-codereview/review.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -251,9 +251,9 @@ func cmdOutputErr(command string, args ...string) (string, error) {
251251
// should be run using runDirErr so that the -v and -n flags apply to them.
252252
func cmdOutputDirErr(dir, command string, args ...string) (string, error) {
253253
// NOTE: We only show these non-state-modifying commands with -v -v.
254-
// Otherwise things like 'git sync -v' show all our internal "find out about
254+
// Otherwise things like 'git codereview sync -v' show all our internal "find out about
255255
// the git repo" commands, which is confusing if you are just trying to find
256-
// out what git sync means.
256+
// out what git codereview sync means.
257257
if *verbose > 1 {
258258
start := time.Now()
259259
defer func() {

git-codereview/submit.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ func cmdSubmit(args []string) {
5959
}
6060

6161
// Sync client to revision that Gerrit committed, but only if we can do it cleanly.
62-
// Otherwise require user to run 'git sync' themselves (if they care).
62+
// Otherwise require user to run 'git codereview sync' themselves (if they care).
6363
run("git", "fetch", "-q")
6464
if len(cs) == 1 && len(b.Pending()) == 1 {
6565
if err := runErr("git", "checkout", "-q", "-B", b.Name, g.CurrentRevision, "--"); err != nil {
@@ -166,7 +166,7 @@ func submitCheck(g *GerritChange) error {
166166
// Not yet "MERGED", so try the submit.
167167
// "SUBMITTED" is a weird state. It means that Submit has been clicked once,
168168
// but it hasn't happened yet, usually because of a merge failure.
169-
// The user may have done git sync and may now have a mergable
169+
// The user may have done git codereview sync and may now have a mergable
170170
// copy waiting to be uploaded, so continue on as if it were "NEW".
171171

172172
case "MERGED":

git-codereview/sync.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ func cmdSync(args []string) {
4949
checkUnstaged("sync")
5050

5151
// Pull remote changes into local branch.
52-
// We do this in one command so that people following along with 'git sync -v'
52+
// We do this in one command so that people following along with 'git codereview sync -v'
5353
// see fewer commands to understand.
5454
// We want to pull in the remote changes from the upstream branch
5555
// and rebase the current pending commit (if any) on top of them.

0 commit comments

Comments
 (0)