Skip to content

Instantly share code, notes, and snippets.

@SavSanta
Created January 20, 2026 18:04
Show Gist options
  • Select an option

  • Save SavSanta/4dbad8761fe8a39d0c43bcb98fc475ef to your computer and use it in GitHub Desktop.

Select an option

Save SavSanta/4dbad8761fe8a39d0c43bcb98fc475ef to your computer and use it in GitHub Desktop.
Someones sample Live Reload TaskFile
#https://www.reddit.com/user/Great_Piece4755/
version: "3"
tasks:
dev:
desc: "build and run binary"
cmds:
- go run .
watch:templ:
desc: "generate go files from templ and restart binary"
cmds:
- |
TEMPL_DEV_MODE=true templ generate --watch -v \
--proxy="http://localhost:8088" --proxybind="0.0.0.0" \
--cmd="go run ." \
--open-browser=false \
-v
watch:css:
desc: "Reload browser on CSS changes"
deps:
- dev
watch: true
sources:
- "assets/**/*.css"
cmds:
- templ generate --notify-proxy
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment