Thread (25 messages) 25 messages, 6 authors, 2016-06-15

Re: [PATCH 2/3] generate-cmdlist.sh: parse common group commands

flat view

From: Eric Sunshine <hidden>
Date: 2016-06-15 23:04:41

On Thu, May 7, 2015 at 11:20 PM, Eric Sunshine [off-list ref] wrote:
quoted hunk ↗ jump to hunk
From: Eric Sunshine <redacted>
Subject: [PATCH] generate-cmdlist: parse common group commands

Signed-off-by: Eric Sunshine <redacted>
---
diff --git a/generate-cmdlist.awk b/generate-cmdlist.awk
new file mode 100644
index 0000000..19b36e5
--- /dev/null
+++ b/generate-cmdlist.awk
@@ -0,0 +1,39 @@
[...]
+state == 1 {
+       grp[$1] = ++n
+       sub($1"[        ][      ]*", "")
+       printf "\tN_(\"%s\"),\n", $0
+       next
By the way, this 'next' line can be deleted. It was leftover gunk from
an earlier iteration. It doesn't harm, but doesn't help either, and is
thus potentially confusing.
quoted hunk ↗ jump to hunk
+}
+/\[common\]/ {
+       state = 1
+}
+END { print "};" }
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help