From 854b2a652ff473c9d2eaa3222008d4baed36ae63 Mon Sep 17 00:00:00 2001 From: Bruce Hill Date: Tue, 17 Jul 2018 17:53:07 -0700 Subject: Fixed a bug in text escapes in nomsu codegen. --- tools/autoformat.nom | 6 ++++++ tools/upgrade.nom | 10 ++++++++++ 2 files changed, 16 insertions(+) create mode 100644 tools/autoformat.nom create mode 100644 tools/upgrade.nom (limited to 'tools') diff --git a/tools/autoformat.nom b/tools/autoformat.nom new file mode 100644 index 0000000..a755b09 --- /dev/null +++ b/tools/autoformat.nom @@ -0,0 +1,6 @@ +use "core" +use "lib/os.nom" + +for %path in (=lua "arg"): + for file %filename in %path: + say ((parse (read file %filename) from %filename) as nomsu) diff --git a/tools/upgrade.nom b/tools/upgrade.nom new file mode 100644 index 0000000..e55d835 --- /dev/null +++ b/tools/upgrade.nom @@ -0,0 +1,10 @@ +use "core" +use "compatibility" +use "lib/os.nom" + +for %path in (=lua "arg"): + for file %filename in %path: + %tree <- (parse (read file %filename) from %filename) + %tree <- (%tree upgraded from %tree.version to (Nomsu version)) + say "#!/usr/bin/env nomsu -V\(Nomsu version)\n\(%tree as nomsu)" + -- cgit v1.2.3