return update_ref(NULL, "ORIG_HEAD", &oid, NULL, 0, UPDATE_REFS_MSG_ON_ERR);
}
- if (get_oid("HEAD", &head) || !(commit = lookup_commit(&head)) ||
+ static int stopped_at_head(void)
+ {
+ struct object_id head;
+ struct commit *commit;
+ struct commit_message message;
+
++ if (get_oid("HEAD", &head) ||
++ !(commit = lookup_commit(the_repository, &head)) ||
+ parse_commit(commit) || get_message(commit, &message))
+ fprintf(stderr, _("Stopped at HEAD\n"));
+ else {
+ fprintf(stderr, _("Stopped at %s\n"), message.label);
+ free_message(commit, &message);
+ }
+ return 0;
+
+ }
+
static const char rescheduled_advice[] =
N_("Could not execute the todo command\n"
"\n"
action=pick
for line in $FAKE_LINES; do
case $line in
- squash|fixup|edit|reword|drop)
+ pick|squash|fixup|edit|reword|drop)
action="$line";;
- exec*)
+ exec*|break)
echo "$line" | sed 's/_/ /g' >> "$1";;
"#")
echo '# comment' >> "$1";;