Files
qt5-legatus-legacy/Lts/Tools/ArAssetsV3/watch
T
2026-08-13 18:33:10 +02:00

18 lines
411 B
Bash
Executable File

#!/bin/sh
# Autocompiles when saving changes
cleanup() {
trap - EXIT # Clear EXIT trap
rm -rf ./tmp # Delete transpiled code
clear # Clear screen
kill -- -$$ # Exit
}
trap cleanup EXIT # Execute cleanup on exit
tsc --watch & # Transpiling
sleep 5 # Wait for transpiling to start in watch mode
watchify ./tmp/* -o ./www/main.js > /dev/null # Browserify silently
trap - EXIT # Just to be sure