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

Automate version bumps #107

Open
yvesgurcan opened this issue Jan 23, 2020 · 0 comments
Open

Automate version bumps #107

yvesgurcan opened this issue Jan 23, 2020 · 0 comments
Labels
🏗️ CI/CD Relates to builds, deployments, or publications

Comments

@yvesgurcan
Copy link
Owner

yvesgurcan commented Jan 23, 2020

Problem

It would be great if version bumps could be handled when creating the build in GitHub instead of having to do version bumps manually with npm.

Solution

Create a custom GitHub Action forked from paulhatch/semantic-version (https://github.com/marketplace/actions/git-semantic-version) that takes a github_token.

            - name: Version bump
              uses: paulhatch/semantic-version@v2
              with:
                branch: ${{ github.head_ref }}
                # A string which, if present in a git commit, indicates that a change represents a major change
                major_pattern: "(MAJOR)"
                # Same as above except indicating a minor change
                minor_pattern: "(MINOR)"
                # A string to determine the format of the version output
                format: "${major}.${minor}.${patch}"
                github_token: ${{ secrets.GITHUB_TOKEN }}
@yvesgurcan yvesgurcan added the 🏗️ CI/CD Relates to builds, deployments, or publications label Jan 23, 2020
@yvesgurcan yvesgurcan changed the title CI/CD: Automate version bumps Automate version bumps Jan 23, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🏗️ CI/CD Relates to builds, deployments, or publications
Projects
None yet
Development

No branches or pull requests

1 participant