Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: Add automatic version bumping #412

Merged
merged 1 commit into from
Feb 4, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .github/pr-title-checker-config.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"CHECKS": {
"regexp": "(build|chore|ci|docs|style|refactor|perf|test|feat|minor|MAJOR|BREAKING CHANGE)(\\(.+\\))?!?\\:"
}
}
27 changes: 27 additions & 0 deletions .github/workflows/bump_version.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
name: Bump Package Version
on:
push:
branches:
- master
jobs:
bump:
runs-on: ubuntu-latest
steps:
- uses: 'actions/checkout@v2'
with:
ref: ${{ github.ref }}
- name: 'Setup Node.js'
uses: 'actions/setup-node@v1'
with:
node-version: 12
- name: 'Automated Version Bump'
id: version-bump
uses: 'phips28/gh-action-bump-version@master'
with:
tag-prefix: 'v'
minor-wording: 'feat:,feat(,minor'
major-wording: 'MAJOR,BREAKING CHANGE'
# build,chore,ci,docs,style,refactor,perf,test
patch-wording: 'build:,build(,chore:,chore(,ci:,ci(,docs:,docs(,style:,style(,refactor:,refactor(,perf:,perf(,test:,test('
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
17 changes: 17 additions & 0 deletions .github/workflows/pr_title_check.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
name: 'PR Title Checker'
on:
pull_request:
types:
- opened
- edited
- synchronize
- labeled
- unlabeled

jobs:
check:
runs-on: ubuntu-latest
steps:
- uses: thehanimo/[email protected]
with:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
2 changes: 1 addition & 1 deletion .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ jobs:
update:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
- uses: actions/checkout@v2
- name: Publish to Registry
uses: elgohr/Publish-Docker-Github-Action@master
with:
Expand Down
22 changes: 22 additions & 0 deletions docs_website/docs/developer_guide/contributing.md
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,28 @@ To increase the chances that your pull request will be accepted:
- Write tests for your changes
- Write a good commit message

### Pull Request Format

When you create a new pull request, please make sure it's title follows the specifications in https://www.conventionalcommits.org/en/v1.0.0/. This is to ensure automatic versioning.

Here are all the prefix allowed by Querybook:

- **patch change**
- build
- chore
- ci
- docs
- style
- refactor
- perf
- test
- **minor change**
- feat
- minor
- **major change**
- MAJOR
- BREAKING CHANGE

## Help

Start by reading the developer starter guide [this guide](./developer_setup.md) to setup Querybook/
Expand Down