redvault-ai/llama_forge_rs/.dist/watch.fish

16 lines
352 B
Fish
Raw Normal View History

2024-07-21 02:42:48 +02:00
#!/usr/bin/env fish
echo "watchPWD: $(pwd)"
set DIRECTORY_TO_WATCH "./src"
set SCRIPT_TO_RUN "echo a && leptosfmt $(pwd) && rustywind --write ./src && echo b"
while true
# Wait for any change in the directory
inotifywait -r -e modify,create,delete,move $DIRECTORY_TO_WATCH
# Run your script
bash -c "$SCRIPT_TO_RUN"
sleep 5
end