diff options
Diffstat (limited to 'tools')
| -rw-r--r-- | tools/autoformat.nom | 5 | ||||
| -rw-r--r-- | tools/upgrade.nom | 16 |
2 files changed, 10 insertions, 11 deletions
diff --git a/tools/autoformat.nom b/tools/autoformat.nom index 6a117ec..7126608 100644 --- a/tools/autoformat.nom +++ b/tools/autoformat.nom @@ -1,7 +1,6 @@ -#!/usr/bin/env nomsu -V 2.2.4.3 +#!/usr/bin/env nomsu -V2.3.4.3 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) + say ((parse (read file %filename) from %filename) as nomsu)
\ No newline at end of file diff --git a/tools/upgrade.nom b/tools/upgrade.nom index 26b01bd..14f7ee0 100644 --- a/tools/upgrade.nom +++ b/tools/upgrade.nom @@ -1,19 +1,19 @@ -#!/usr/bin/env Nomsu -V 2.2.4.3 +#!/usr/bin/env Nomsu -V2.3.4.3 use "core" use "compatibility" use "lib/os.nom" -%args <- (command line args) -%inplace <- (no) +%args = (command line args) +%inplace = (no) if (%args.1 is "-i"): - %inplace <- (yes) + %inplace = (yes) remove index 1 from %args for %path in %args: - if (%path is "-i"): %inplace <- (yes) + if (%path is "-i"): %inplace = (yes) for file %filename in %path: - %tree <- (parse (read file %filename) from %filename) - %tree <- (%tree upgraded from %tree.version to (Nomsu version)) - %text <- "#!/usr/bin/env nomsu -V\(Nomsu version)\n\(%tree as nomsu)" + %tree = (parse (read file %filename) from %filename) + %tree = (%tree upgraded from %tree.version to (Nomsu version)) + %text = "#!/usr/bin/env nomsu -V\(Nomsu version)\n\(%tree as nomsu)" if %inplace: write %text to file %filename ..else: |
