about summary refs log tree commit diff stats
path: root/tools/treeshake_translate
diff options
context:
space:
mode:
Diffstat (limited to 'tools/treeshake_translate')
-rwxr-xr-xtools/treeshake_translate8
1 files changed, 8 insertions, 0 deletions
diff --git a/tools/treeshake_translate b/tools/treeshake_translate
new file mode 100755
index 00000000..ba80dea0
--- /dev/null
+++ b/tools/treeshake_translate
@@ -0,0 +1,8 @@
+#!/bin/sh
+# Translate SubX into minified ELF binaries for Linux.
+
+set -e
+
+grep -vh '^\s*#\|^\s*$' $*  > a.in
+cat a.in  |tools/treeshake  > a.treeshake
+./ntranslate a.treeshake