-
-
Notifications
You must be signed in to change notification settings - Fork 68
/
justfile
29 lines (23 loc) · 733 Bytes
/
justfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
#!/usr/bin/env just --justfile
# List available recipes
default:
@just --list
# Get coverage profile
coverage:
go test -v -coverprofile=profile.cov ./...
# Linting and static checks
lint:
golangci-lint -c .golangci.yml run
# Run tests
test:
go test -v ./...
branch := `git branch --show-current`
# Bump version in changelog and create commit + tag on current branch
cut-release $NEW_VERSION:
just lint
just test
sed -i "s/## \[Unreleased]\s*\n*/## [Unreleased]\n\n## [$NEW_VERSION] $(date +'%Y-%m-%d')/g" CHANGELOG.md
echo "[$NEW_VERSION]: https://github.com/bebop/poly/releases/tag/v$NEW_VERSION" >> CHANGELOG.md
git add CHANGELOG.md
git commit -m "Release version v$NEW_VERSION"
git tag v$NEW_VERSION