7 sh: git describe --long 2>/dev/null || echo ""
9 sh: test -f race.log && echo "1" || echo ""
13 GOEXPERIMENT: greenteagc
17 desc: Install golangci-lint
19 - go install github.com/golangci/golangci-lint/v2/cmd/golangci-lint@latest
24 desc: Run base linters
27 - golangci-lint run --path-mode=abs --config=".golangci.yml" --timeout=5m
32 desc: Check that log messages start with capital letters
34 - ./scripts/check_log_capitalization.sh
37 desc: Run base linters and fix issues
39 - golangci-lint run --path-mode=abs --config=".golangci.yml" --timeout=5m --fix
46 LDFLAGS: '{{if .VERSION}}-ldflags="-X github.com/charmbracelet/crush/internal/version.Version={{.VERSION}}"{{end}}'
48 - "go build -v {{if .RACE}}-race{{end}} {{.LDFLAGS}} ."
52 - internal/agent/**/*.md
53 - internal/agent/**/*.md.tpl
61 - "./crush{{exeExt}} {{.CLI_ARGS}} {{if .RACE}}2>race.log{{end}}"
64 desc: Run build with local Catwalk
66 CATWALK_URL: http://localhost:8080
69 - ./crush{{exeExt}} {{.CLI_ARGS}}
72 desc: Run build with custom config to test onboarding
74 CRUSH_GLOBAL_DATA: tmp/onboarding/data
75 CRUSH_GLOBAL_CONFIG: tmp/onboarding/config
78 - rm -rf tmp/onboarding
79 - ./crush{exeExt} {{.CLI_ARGS}}
84 - go test -race -failfast ./... {{.CLI_ARGS}}
87 desc: Run tests and record all VCR cassettes again
90 - rm -r internal/agent/testdata
91 - go test -v -count=1 -timeout=1h ./internal/agent
99 desc: Run prettier on HTML/CSS/JS files
101 - prettier --write internal/cmd/stats/index.html internal/cmd/stats/index.css internal/cmd/stats/index.js
106 - go run golang.org/x/tools/go/analysis/passes/modernize/cmd/modernize@latest -fix -test ./...
109 desc: Run with profiling enabled
116 desc: Install the application
118 LDFLAGS: '{{if .VERSION}}-ldflags="-X github.com/charmbracelet/crush/internal/version.Version={{.VERSION}}"{{end}}'
121 - go install {{.LDFLAGS}} -v .
125 - internal/agent/**/*.md
126 - internal/agent/**/*.md.tpl
129 desc: 10s CPU profile
131 - go tool pprof -http :6061 'http://localhost:6060/debug/pprof/profile?seconds=10'
136 - go tool pprof -http :6061 'http://localhost:6060/debug/pprof/heap'
139 desc: Allocations profile
141 - go tool pprof -http :6061 'http://localhost:6060/debug/pprof/allocs'
144 desc: Generate JSON schema for configuration
146 - go run main.go schema > schema.json
147 - echo "Generated schema.json"
152 desc: Update Hyper embedded provider.json
154 - go generate ./internal/agent/hyper/...
156 - ./internal/agent/hyper/provider.json
159 desc: Create and push a new tag following semver
162 sh: svu next --always || go run github.com/caarlos0/svu/v3@latest next --always
163 prompt: "This will release {{.NEXT}}. Continue?"
165 - sh: '[ $(git symbolic-ref --short HEAD) = "main" ]'
166 msg: Not on main branch
167 - sh: "[ $(git status --porcelain=2 | wc -l) = 0 ]"
169 - sh: 'gh run list --workflow build.yml --commit $(git rev-parse HEAD) --status success --json conclusion -q ".[0].conclusion" | grep -q success'
170 msg: "Test build for this commit failed or not present"
171 - sh: 'gh run list --workflow snapshot.yml --commit $(git rev-parse HEAD) --status success --json conclusion -q ".[0].conclusion" | grep -q success'
172 msg: "Snapshot build for this commit failed or not present"
175 - git commit --allow-empty -m "{{.NEXT}}"
176 - git tag --annotate --sign -m "{{.NEXT}}" {{.NEXT}} {{.CLI_ARGS}}
177 - echo "Pushing {{.NEXT}}..."
178 - git push origin main --follow-tags
182 - git tag -d nightly || true
186 desc: Update Fantasy and Catwalk
188 # The Go proxy takes a bit of time to see the latest release. Setting
189 # these bypass it to ensure we can update to a release from a minute ago.
191 GONOSUMDB: charm.land/*
193 - go get charm.land/fantasy@latest
194 - go get charm.land/catwalk@latest
198 desc: Generate code using SQLC
keysesc to close
- j k
- move down, up
- enter
- open
- esc
- back, or up a level
- 1 2 3 4
- readme, files, commits, refs
- /
- filter
- y
- copy the clone command
- c
- compare the chosen commit with another (or shift-click both)
- ?
- show or hide this list