t/README: link to metacpan.org, not search.cpan.org
[gitweb.git] / wt-status.c
index 4dff0b3e2108bbd41e638c7beb69e62b20fa8740..234e77a6d6d5cead70ff72e984c11bb7621faad6 100644 (file)
@@ -628,7 +628,7 @@ static void wt_status_collect_changes_initial(struct wt_status *s)
                        d->index_status = DIFF_STATUS_ADDED;
                        /* Leave {mode,oid}_head zero for adds. */
                        d->mode_index = ce->ce_mode;
-                       hashcpy(d->oid_index.hash, ce->oid.hash);
+                       oidcpy(&d->oid_index, &ce->oid);
                }
        }
 }
@@ -1730,12 +1730,14 @@ static void wt_shortstatus_print_tracking(struct wt_status *s)
                return;
        branch_name = s->branch;
 
+#define LABEL(string) (s->no_gettext ? (string) : _(string))
+
        if (s->is_initial)
-               color_fprintf(s->fp, header_color, _("Initial commit on "));
+               color_fprintf(s->fp, header_color, LABEL(N_("Initial commit on ")));
 
        if (!strcmp(s->branch, "HEAD")) {
                color_fprintf(s->fp, color(WT_STATUS_NOBRANCH, s), "%s",
-                             _("HEAD (no branch)"));
+                             LABEL(N_("HEAD (no branch)")));
                goto conclude;
        }
 
@@ -1760,8 +1762,6 @@ static void wt_shortstatus_print_tracking(struct wt_status *s)
        if (!upstream_is_gone && !num_ours && !num_theirs)
                goto conclude;
 
-#define LABEL(string) (s->no_gettext ? (string) : _(string))
-
        color_fprintf(s->fp, header_color, " [");
        if (upstream_is_gone) {
                color_fprintf(s->fp, header_color, LABEL(N_("gone")));
@@ -2102,7 +2102,7 @@ static void wt_porcelain_v2_print_unmerged_entry(
                if (strcmp(ce->name, it->string) || !stage)
                        break;
                stages[stage - 1].mode = ce->ce_mode;
-               hashcpy(stages[stage - 1].oid.hash, ce->oid.hash);
+               oidcpy(&stages[stage - 1].oid, &ce->oid);
                sum |= (1 << (stage - 1));
        }
        if (sum != d->stagemask)