Skip to content

Commit

Permalink
fast-export: rename the signed tag mode 'ignore' to 'verbatim'
Browse files Browse the repository at this point in the history
The name 'verbatim' describes much better what this mode does with
signed tags.  While at it, fix the documentation what it actually
does.

Signed-off-by: Johannes Schindelin <[email protected]>
Signed-off-by: Junio C Hamano <[email protected]>
  • Loading branch information
dscho authored and gitster committed Dec 4, 2007
1 parent 14c9821 commit ee4bc37
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 8 deletions.
4 changes: 2 additions & 2 deletions Documentation/git-fast-export.txt
Original file line number Diff line number Diff line change
Expand Up @@ -26,14 +26,14 @@ OPTIONS
Insert 'progress' statements every <n> objects, to be shown by
gitlink:git-fast-import[1] during import.

--signed-tags=(ignore|warn|strip|abort)::
--signed-tags=(verbatim|warn|strip|abort)::
Specify how to handle signed tags. Since any transformation
after the export can change the tag names (which can also happen
when excluding revisions) the signatures will not match.
+
When asking to 'abort' (which is the default), this program will die
when encountering a signed tag. With 'strip', the tags will be made
unsigned, with 'ignore', they will be silently ignored (i.e. not exported)
unsigned, with 'verbatim', they will be silently exported
and with 'warn', they will be exported, but you will see a warning.


Expand Down
8 changes: 4 additions & 4 deletions builtin-fast-export.c
Original file line number Diff line number Diff line change
Expand Up @@ -23,15 +23,15 @@ static const char *fast_export_usage[] = {
};

static int progress;
static enum { IGNORE, WARN, STRIP, ABORT } signed_tag_mode = ABORT;
static enum { VERBATIM, WARN, STRIP, ABORT } signed_tag_mode = ABORT;

static int parse_opt_signed_tag_mode(const struct option *opt,
const char *arg, int unset)
{
if (unset || !strcmp(arg, "abort"))
signed_tag_mode = ABORT;
else if (!strcmp(arg, "ignore"))
signed_tag_mode = IGNORE;
else if (!strcmp(arg, "verbatim") || !strcmp(arg, "ignore"))
signed_tag_mode = VERBATIM;
else if (!strcmp(arg, "warn"))
signed_tag_mode = WARN;
else if (!strcmp(arg, "strip"))
Expand Down Expand Up @@ -270,7 +270,7 @@ static void handle_tag(const char *name, struct tag *tag)
warning ("Exporting signed tag %s",
sha1_to_hex(tag->object.sha1));
/* fallthru */
case IGNORE:
case VERBATIM:
break;
case STRIP:
message_size = signature + 1 - message;
Expand Down
4 changes: 2 additions & 2 deletions t/t9301-fast-export.sh
Original file line number Diff line number Diff line change
Expand Up @@ -106,9 +106,9 @@ test_expect_success 'signed-tags=abort' '
'

test_expect_success 'signed-tags=ignore' '
test_expect_success 'signed-tags=verbatim' '
git fast-export --signed-tags=ignore sign-your-name > output &&
git fast-export --signed-tags=verbatim sign-your-name > output &&
grep PGP output
'
Expand Down

0 comments on commit ee4bc37

Please sign in to comment.