small pixel drawing of a pufferfish zoa

*
Jes Olson j3s@c3f.net
Tue, 27 Sep 2022 23:14:49 -0500
commit

bac40616ec0bc7b038b761d7c13a7d6e06838662

parent

6f26d8d7adf2a59d5f2918220a625742ed556711

1 files changed, 4 insertions(+), 2 deletions(-)

jump to
M shell/shell.goshell/shell.go

@@ -34,8 +34,8 @@ // execute every statement individually, decorating

// each with ->, and doing some speshul logicks against // certain strings for _, stmt := range script.Stmts { - cmdName := commandName(stmt) - command, after, _ := strings.Cut(cmdName, " ") + fullCmd := commandName(stmt) + command, after, _ := strings.Cut(fullCmd, " ") if command == "zoa-script" { // recursion detected!!!!!! :3 :3 :3

@@ -117,6 +117,8 @@

func commandName(statement *syntax.Stmt) string { b := new(bytes.Buffer) syntax.NewPrinter().Print(b, statement) + command := b.String() + command = strings.Trim(command, "\n ") return b.String() }