Skip to content

Commit

Permalink
allow empty commits to avoid errors in corner cases
Browse files Browse the repository at this point in the history
It is safer to get empty commit than to process corner cases, proved
also by testing :)

Signed-off-by: Denis Zalevskiy <denis.zalevskiy@jolla.com>
  • Loading branch information
Denis Zalevskiy committed Aug 25, 2014
1 parent f97eff3 commit 066eac0
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions tools/git-vault-rebase-generate.awk
Expand Up @@ -36,7 +36,7 @@ function prepare_commands() {
cmd="git cherry-pick " ids[1];
for (i = 1; i <= length(ids); i++) {
cmd = cmd " && git cherry-pick --no-commit " ids[i] \
" && git commit --no-edit --amend";
" && git commit --no-edit --amend --allow-empty";
}
push_command(cmd);
}
Expand All @@ -53,7 +53,7 @@ function prepare_commands() {
}
array_clear(old_tags);
push_command("git cherry-pick --no-commit " id);
push_command("git commit --no-edit --amend");
push_command("git commit --no-edit --amend --allow-empty");
} else {
push_echo("tag " tag);
push_command("git cherry-pick " id);
Expand All @@ -79,7 +79,7 @@ $1 == "old_tag" {
push(old_tags, length(old_tags), "git cherry-pick " $2);
} else {
push(old_tags, length(old_tags), "git cherry-pick --no-commit " $2);
push(old_tags, length(old_tags), "git commit --no-edit --amend");
push(old_tags, length(old_tags), "git commit --no-edit --amend --allow-empty");
}
}

Expand Down

0 comments on commit 066eac0

Please sign in to comment.