summaryrefslogtreecommitdiff
path: root/tnslc/run.ps1
diff options
context:
space:
mode:
Diffstat (limited to 'tnslc/run.ps1')
-rw-r--r--tnslc/run.ps18
1 files changed, 5 insertions, 3 deletions
diff --git a/tnslc/run.ps1 b/tnslc/run.ps1
index 620673d..1994257 100644
--- a/tnslc/run.ps1
+++ b/tnslc/run.ps1
@@ -1,8 +1,10 @@
if ($args.Length -gt 0) {
..\tint.exe -flags "$args" -in tnslc.tnsl
- nasm -f win64 -o "$($args[0]).obj" "$($args[0]).asm"
- gcc -o "$($args[0]).exe" "$($args[0]).obj"
+ mkdir -Force build
+ mv -Force "$($args[0]).asm" "build/$($args[0]).asm"
+ nasm -f win64 -o "build/$($args[0]).obj" "build/$($args[0]).asm"
+ gcc -o "build/$($args[0]).exe" "build/$($args[0]).obj"
} else {
Write-Host "Usage: run [file to compile]";
Write-Host "";
-} \ No newline at end of file
+}