aboutsummaryrefslogtreecommitdiff
path: root/scripts/genconfig.sh
diff options
context:
space:
mode:
Diffstat (limited to 'scripts/genconfig.sh')
-rwxr-xr-xscripts/genconfig.sh16
1 files changed, 16 insertions, 0 deletions
diff --git a/scripts/genconfig.sh b/scripts/genconfig.sh
new file mode 100755
index 00000000..59c63c5b
--- /dev/null
+++ b/scripts/genconfig.sh
@@ -0,0 +1,16 @@
+#!/bin/bash
+
+mkdir -p generated
+
+function genconfig()
+{
+ for i in $(echo toys/*.c | sort)
+ do
+ # Grab the config block for Config.in
+ echo "# $i"
+ sed -n '/^\*\//q;/^config [A-Z]/,$p' $i || exit 1
+ echo
+ done
+}
+
+genconfig > generated/Config.in