@@ -438,3 +438,90 @@ tasks:
438438 ignore_error : true
439439 - cmd : ' {{.RMRF}} "dist"'
440440 ignore_error : true
441+
442+ tsunami:demo:todo :
443+ desc : Run the tsunami todo demo application
444+ cmd : go run demo/todo/*.go
445+ dir : tsunami
446+ env :
447+ TSUNAMI_LISTENADDR : " localhost:12026"
448+
449+ tsunami:frontend:dev :
450+ desc : Run the tsunami frontend vite dev server
451+ cmd : npm run dev
452+ dir : tsunami/frontend
453+
454+ tsunami:frontend:build :
455+ desc : Build the tsunami frontend
456+ cmd : yarn build
457+ dir : tsunami/frontend
458+
459+ tsunami:frontend:devbuild :
460+ desc : Build the tsunami frontend in development mode (with source maps and symbols)
461+ cmd : yarn build:dev
462+ dir : tsunami/frontend
463+
464+ tsunami:scaffold :
465+ desc : Build scaffold for tsunami frontend development
466+ deps :
467+ - tsunami:frontend:build
468+ cmds :
469+ - task : tsunami:scaffold:internal
470+
471+ tsunami:devscaffold :
472+ desc : Build scaffold for tsunami frontend development (with source maps and symbols)
473+ deps :
474+ - tsunami:frontend:devbuild
475+ cmds :
476+ - task : tsunami:scaffold:internal
477+
478+ tsunami:scaffold:internal :
479+ desc : Internal task to create scaffold directory structure
480+ dir : tsunami/frontend
481+ internal : true
482+ cmds :
483+ - cmd : " {{.RMRF}} scaffold"
484+ ignore_error : true
485+ - mkdir scaffold
486+ - cd scaffold && npm --no-workspaces init -y --init-license Apache-2.0
487+ - cd scaffold && npm pkg set name=tsunami-scaffold
488+ - cd scaffold && npm pkg delete author
489+ - cd scaffold && npm pkg set author.name="Command Line Inc"
490+ - cd scaffold && npm pkg set author.email="info@commandline.dev"
491+ - cd scaffold && npm --no-workspaces install tailwindcss @tailwindcss/cli
492+ - cp -r dist scaffold/
493+ - cp ../templates/app-main.go.tmpl scaffold/app-main.go
494+ - cp ../templates/tailwind.css scaffold/
495+ - cp ../templates/gitignore.tmpl scaffold/.gitignore
496+
497+ tsunami:build :
498+ desc : Build the tsunami binary.
499+ cmds :
500+ - cmd : " {{.RM}} bin/tsunami*"
501+ ignore_error : true
502+ - mkdir -p bin
503+ - cd tsunami && go build -ldflags "-X main.BuildTime=$({{.DATE}} +'%Y%m%d%H%M') -X main.TsunamiVersion={{.VERSION}}" -o ../bin/tsunami{{exeExt}} cmd/main-tsunami.go
504+ sources :
505+ - " tsunami/**/*.go"
506+ - " tsunami/go.mod"
507+ - " tsunami/go.sum"
508+ generates :
509+ - " bin/tsunami{{exeExt}}"
510+
511+ tsunami:clean :
512+ desc : Clean tsunami frontend build artifacts
513+ dir : tsunami/frontend
514+ cmds :
515+ - cmd : " {{.RMRF}} dist"
516+ ignore_error : true
517+ - cmd : " {{.RMRF}} scaffold"
518+ ignore_error : true
519+
520+ godoc :
521+ desc : Start the Go documentation server for the root module
522+ cmd : $(go env GOPATH)/bin/pkgsite -http=:6060
523+
524+ tsunami:godoc :
525+ desc : Start the Go documentation server for the tsunami module
526+ cmd : $(go env GOPATH)/bin/pkgsite -http=:6060
527+ dir : tsunami
0 commit comments