From 672f45a63cf7d5a7cd291c8171864870ecca888f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ismael=20Venegas=20Castell=C3=B3?= Date: Sat, 17 Aug 2024 21:45:04 -0600 Subject: [PATCH] fix makefile --- makefile | 11 +++-------- src/repl/routines.tal | 4 ++-- 2 files changed, 5 insertions(+), 10 deletions(-) diff --git a/makefile b/makefile index 7706e72..431581d 100644 --- a/makefile +++ b/makefile @@ -32,12 +32,7 @@ setup: @ echo "Setting up: ~/{${BIN_DIR},${ROMS_DIR}}" @ mkdir -p ~/${BIN_DIR} ~/${ROMS_DIR} -backup: - @ echo "Backing: ./{${BIN_DIR},${ROM_DIR}}/* to ./${BAK_DIR}" - @ cp ${BIN_DIR}/* ${BAK_DIR} - @ cp ${ROM_DIR}/* ${BAK_DIR} - -build: backup ${ROM} +build: ${ROM} @ echo "Building: ./${ROM}*" @ cd ${SRC_DIR} && ${ASM} ${TAL} ../${ROM} @@ -53,14 +48,14 @@ disassemble: build @ echo "Disassembling: ./${ROM}.dis" @ ${EMU} ${DIS} ${ROM} > ${ROM}.dis -install: setup backup build dump symbols disassemble +install: setup build dump symbols disassemble @ echo "Installing: ./{${BIN_DIR},${ROM_DIR}}/* at ~/{${BIN_DIR},${ROMS_DIR}}" @ cp ${BIN_DIR}/* ~/${BIN_DIR} @ cp ${ROM} ~/${ROMS_DIR} test: install @ echo "Testing: ~/${ROM_DIR}/${ID}.rom" - @ echo "~test/routines.tal \n sierpinski" | ${EMU} ${ROM_DIR}/${ID}.rom + @ echo "~test/routines.tal\nsierpinski\nbye" | ${EMU} ${ROM_DIR}/${ID}.rom cli: install @ echo "Running: ~/${BIN_DIR}/${ID}-cli" diff --git a/src/repl/routines.tal b/src/repl/routines.tal index 045b18f..b9af505 100644 --- a/src/repl/routines.tal +++ b/src/repl/routines.tal @@ -102,10 +102,10 @@ [ LIT &in-esc 01 ] ?{ #01 ,&in-esc STR - DUP LIT \r NEQ ?{ + DUPk LIT \r NEQ SWP LIT \n NEQ AND ?{ ,&multiline LDR #00 EQU ,&multiline STR } } - DUP LIT \r NEQ ?{ + DUPk LIT \r NEQ SWP LIT \n NEQ AND ?{ [ LIT &multiline 01 ] ?{ pstr: \reset-console-style \bold \bg-0 \fg-3 \0 ~logger/info/multiline-prompt.tal