commit ea6a61126ad914ff9811325d041ed06673e3d4c2
parent 0d43e40b023b104e36cf2802f0bde64ba2150066
Author: Quentin Rameau <quinq@fifth.space>
Date: Thu, 22 Jun 2017 19:07:37 +0200
Add ! command to refetch current failed item
Diffstat:
1 file changed, 7 insertions(+), 0 deletions(-)
diff --git a/sacc.c b/sacc.c
@@ -90,6 +90,7 @@ help(void)
puts("Commands:\n"
"N = [1-9]...: browse item N.\n"
"0: browse previous item.\n"
+ "!: refetch failed item.\n"
"^D, q: quit.\n"
"h: this help.");
}
@@ -347,6 +348,12 @@ selectitem(Item *entry)
if (!strcmp(buf, "q\n"))
return NULL;
+ if (!strcmp(buf, "!\n")) {
+ if (entry->raw)
+ continue;
+ return entry;
+ }
+
item = -1;
if (!strcmp(buf, "h\n")) {
help();