]> git.ipfire.org Git - thirdparty/git.git/commitdiff
messages: avoid SHA-1 in end-user facing messages
authorJunio C Hamano <gitster@pobox.com>
Fri, 14 Aug 2020 01:07:12 +0000 (18:07 -0700)
committerJunio C Hamano <gitster@pobox.com>
Fri, 14 Aug 2020 16:33:37 +0000 (09:33 -0700)
There are still a handful mentions of SHA-1 when we meant the
(hexadecimal) object names in end-user facing messages.  Rewrite
them.

I was hoping that this can mostly be s/SHA-1/object name/, but
a few messages needed rephrasing to keep the result readable.

Signed-off-by: Junio C Hamano <gitster@pobox.com>
builtin/blame.c
builtin/name-rev.c
builtin/pack-objects.c
parse-options.h
t/t0040-parse-options.sh

index 94ef57c1cc304963452772e24125e5939dff0481..eb513fbe60c34a6de505a9b99da0ff033f612622 100644 (file)
@@ -842,7 +842,7 @@ int cmd_blame(int argc, const char **argv, const char *prefix)
        const char *contents_from = NULL;
        const struct option options[] = {
                OPT_BOOL(0, "incremental", &incremental, N_("Show blame entries as we find them, incrementally")),
-               OPT_BOOL('b', NULL, &blank_boundary, N_("Show blank SHA-1 for boundary commits (Default: off)")),
+               OPT_BOOL('b', NULL, &blank_boundary, N_("Do not show object names of boundary commits (Default: off)")),
                OPT_BOOL(0, "root", &show_root, N_("Do not treat root commits as boundaries (Default: off)")),
                OPT_BOOL(0, "show-stats", &show_stats, N_("Show work cost statistics")),
                OPT_BOOL(0, "progress", &show_progress, N_("Force progress reporting")),
index a9dcd25e46477ef5294dd501f1048816b27b3cdf..725dd04519133595dc212ce6c68e511b07c6b92a 100644 (file)
@@ -521,7 +521,7 @@ int cmd_name_rev(int argc, const char **argv, const char *prefix)
        int all = 0, transform_stdin = 0, allow_undefined = 1, always = 0, peel_tag = 0;
        struct name_ref_data data = { 0, 0, STRING_LIST_INIT_NODUP, STRING_LIST_INIT_NODUP };
        struct option opts[] = {
-               OPT_BOOL(0, "name-only", &data.name_only, N_("print only names (no SHA-1)")),
+               OPT_BOOL(0, "name-only", &data.name_only, N_("print only ref-based names (no object names)")),
                OPT_BOOL(0, "tags", &data.tags_only, N_("only use tags to name the commits")),
                OPT_STRING_LIST(0, "refs", &data.ref_filters, N_("pattern"),
                                   N_("only use refs matching <pattern>")),
index 7016b28485b43f9df360f4f6df23cb7e0e3881dd..414f9f0043cdef1d83824d037993af3185225565 100644 (file)
@@ -3325,7 +3325,7 @@ static void get_object_list(int ac, const char **av)
                        if (starts_with(line, "--shallow ")) {
                                struct object_id oid;
                                if (get_oid_hex(line + 10, &oid))
-                                       die("not an SHA-1 '%s'", line + 10);
+                                       die("not an object name '%s'", line + 10);
                                register_shallow(the_repository, &oid);
                                use_bitmap_index = 0;
                                continue;
index 46af94209305529253c0308a69db9caabd8b6624..7030d8f3da6328cde9557f91cfd80ae60040cfd6 100644 (file)
@@ -314,7 +314,7 @@ int parse_opt_passthru_argv(const struct option *, const char *, int);
 #define OPT__FORCE(var, h, f) OPT_COUNTUP_F('f', "force",   (var), (h), (f))
 #define OPT__ABBREV(var)  \
        { OPTION_CALLBACK, 0, "abbrev", (var), N_("n"), \
-         N_("use <n> digits to display SHA-1s"),       \
+         N_("use <n> digits to display object names"), \
          PARSE_OPT_OPTARG, &parse_opt_abbrev_cb, 0 }
 #define OPT__COLOR(var, h) \
        OPT_COLOR_FLAG(0, "color", (var), (h))
index f8178ee4e392fa5cfdbef07b0f42710ea68bc67b..14cafc138b7875013afeee01d74dbbeb2e56d495 100755 (executable)
@@ -44,7 +44,7 @@ Magic arguments
     --no-ambiguous        negative ambiguity
 
 Standard options
-    --abbrev[=<n>]        use <n> digits to display SHA-1s
+    --abbrev[=<n>]        use <n> digits to display object names
     -v, --verbose         be verbose
     -n, --dry-run         dry run
     -q, --quiet           be quiet