-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat!: change template pipeline to github
- Loading branch information
Showing
8 changed files
with
82 additions
and
55 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
# This is a basic workflow to help you get started with Actions | ||
name: format_and_lint | ||
|
||
# Controls when the workflow will run | ||
on: | ||
# Triggers the workflow on pull request to the main branch | ||
pull_request: | ||
branches: | ||
- main | ||
|
||
# Allows you to run this workflow manually from the Actions tab | ||
workflow_dispatch: | ||
|
||
# A workflow run is made up of one or more jobs that can run sequentially or in parallel | ||
jobs: | ||
# This workflow contains a single job called "build" | ||
format_and_lint: | ||
# The type of runner that the job will run on | ||
runs-on: ubuntu-latest | ||
# Steps represent a sequence of tasks that will be executed as part of the job | ||
steps: | ||
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it | ||
- uses: actions/checkout@v3 | ||
with: | ||
fetch-depth: 0 | ||
- name: setup environment | ||
uses: mamba-org/provision-with-micromamba@main | ||
with: | ||
environment-file: environment.yaml | ||
# Runs a set of commands using the runners shell | ||
- name: run pre-commit & check commit msgs | ||
shell: bash -l {0} | ||
run: | | ||
micromamba activate data-science-project-template | ||
pre-commit install | ||
pre-commit run --hook-stage manual --all-files | ||
git fetch | ||
export branch_name=${{ github.ref_name }} | ||
if [[ ${{ github.event_name }} == "pull_request" ]]; then export branch_name=${{ github.head_ref}}; fi | ||
./check_commit_msgs.sh -c "remotes/origin/${branch_name}" -m "remotes/origin/${{ github.event.repository.default_branch }}" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
name: semantic-release | ||
|
||
# trigger a release of a new version if commits are added to the default branch (e.g., main) | ||
on: | ||
push: | ||
branches: | ||
- 'main' | ||
|
||
env: | ||
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
|
||
jobs: | ||
tag_release: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Use Node.js ${{ matrix.node-version }} | ||
uses: actions/setup-node@v3 | ||
with: | ||
node-version: '16' | ||
- run: npm install semantic-release conventional-changelog-conventionalcommits | ||
- run: npx semantic-release |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -50,7 +50,7 @@ | |
} | ||
} | ||
], | ||
"@semantic-release/gitlab" | ||
"@semantic-release/github" | ||
], | ||
"branches": "main" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters