From d37f378d37d56aa94861a05e459e299ba71c1255 Mon Sep 17 00:00:00 2001 From: Sebastien Jourdain Date: Wed, 18 Aug 2021 14:02:58 -0600 Subject: [PATCH] ci(github): Migrate from travis to github actions --- .github/FUNDING.yml | 3 ++ .github/ISSUE_TEMPLATE/bug_report.md | 42 ++++++++++++++++++ .github/ISSUE_TEMPLATE/config.yml | 5 +++ .github/ISSUE_TEMPLATE/feature_request.md | 24 +++++++++++ .github/ISSUE_TEMPLATE/performance_issue.md | 40 ++++++++++++++++++ .github/pull_request_template.md | 47 +++++++++++++++++++++ .github/workflows/publish.yml | 39 +++++++++++++++++ .travis.yml | 37 ---------------- 8 files changed, 200 insertions(+), 37 deletions(-) create mode 100644 .github/FUNDING.yml create mode 100644 .github/ISSUE_TEMPLATE/bug_report.md create mode 100644 .github/ISSUE_TEMPLATE/config.yml create mode 100644 .github/ISSUE_TEMPLATE/feature_request.md create mode 100644 .github/ISSUE_TEMPLATE/performance_issue.md create mode 100644 .github/pull_request_template.md create mode 100644 .github/workflows/publish.yml delete mode 100644 .travis.yml diff --git a/.github/FUNDING.yml b/.github/FUNDING.yml new file mode 100644 index 0000000..c5494db --- /dev/null +++ b/.github/FUNDING.yml @@ -0,0 +1,3 @@ +# These are supported funding model platforms + +custom: ["https://www.kitware.com/contact-us/", kitware.com] diff --git a/.github/ISSUE_TEMPLATE/bug_report.md b/.github/ISSUE_TEMPLATE/bug_report.md new file mode 100644 index 0000000..e30ca05 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/bug_report.md @@ -0,0 +1,42 @@ +--- +name: 🐞 Bug report +about: Report a reproducible bug or regression. +title: '' +labels: 'type: bug 🐞' +assignees: '' + +--- + + +### High-level description + + +### Steps to reproduce + + +### Detailed behavior + + +### Expected behavior + + +### Environment +- **Visualizer**: +- **OS**: +- **Browser**: diff --git a/.github/ISSUE_TEMPLATE/config.yml b/.github/ISSUE_TEMPLATE/config.yml new file mode 100644 index 0000000..afa2151 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/config.yml @@ -0,0 +1,5 @@ +blank_issues_enabled: false +contact_links: + - name: Help and Support + url: https://discourse.paraview.org/c/web-support/10 + about: Please use the forum if you have questions or need help. \ No newline at end of file diff --git a/.github/ISSUE_TEMPLATE/feature_request.md b/.github/ISSUE_TEMPLATE/feature_request.md new file mode 100644 index 0000000..76c1984 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/feature_request.md @@ -0,0 +1,24 @@ +--- +name: 💡 Feature request +about: Suggest an idea for the project. +title: '' +labels: 'type: feature request 💡' +assignees: '' + +--- + + +### Need + + +### Feature + diff --git a/.github/ISSUE_TEMPLATE/performance_issue.md b/.github/ISSUE_TEMPLATE/performance_issue.md new file mode 100644 index 0000000..cdc835e --- /dev/null +++ b/.github/ISSUE_TEMPLATE/performance_issue.md @@ -0,0 +1,40 @@ +--- +name: ⚡️ Performance issue +about: Report an abnormally slow behavior. +title: '' +labels: 'type: performance ⚡️' +assignees: '' + +--- + + +### High-level description + + +### Steps to reproduce + + +### Current behavior + + +### Environment +- **Visualizer**: +- **OS**: +- **Browser**: diff --git a/.github/pull_request_template.md b/.github/pull_request_template.md new file mode 100644 index 0000000..e20041f --- /dev/null +++ b/.github/pull_request_template.md @@ -0,0 +1,47 @@ + + +### PR and Code Checklist + +- [ ] [semantic-release](https://github.com/semantic-release/semantic-release) commit messages +- [ ] Run `npm run reformat` to have correctly formatted code + +### Context + + +### Changes + + +### Results + + +### Testing + +- [ ] This change adds or fixes unit tests +- [ ] All tests complete without errors on the following environment: + - **Visualizer**: + - **OS**: + - **Browser**: + + +_This contribution is funded by [Example](https://example.com)._ diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml new file mode 100644 index 0000000..a0fa267 --- /dev/null +++ b/.github/workflows/publish.yml @@ -0,0 +1,39 @@ +name: Release +on: + push: + branches: + - master + +jobs: + publish: + name: Publish + runs-on: ubuntu-18.04 + steps: + - name: Checkout + uses: actions/checkout@v2 + with: + fetch-depth: 0 + - name: Setup node + uses: actions/setup-node@v1 + with: + node-version: 12 + - name: Install dependencies + run: npm ci + - name: Build + run: npm run build:release + - name: Validate + run: npm run validate + - name: Release + env: + GITHUB_TOKEN: ${{ secrets.GH_TOKEN }} + GH_TOKEN: ${{ secrets.GH_TOKEN }} + NPM_TOKEN: ${{ secrets.NPM_TOKEN }} + run: | + git config --global user.name "Github Actions" + git config --global user.email "sebastien.jourdain@kitware.com" + npm run semantic-release + - name: Publish docs + if: github.ref == 'refs/heads/master' + env: + GIT_PUBLISH_URL: https://${{ secrets.GH_TOKEN }}@github.com/Kitware/visualizer.git + run: npm run doc:publish diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index c62457f..0000000 --- a/.travis.yml +++ /dev/null @@ -1,37 +0,0 @@ -language: node_js -os: linux -sudo: required -dist: trusty -group: travis_lts - -notifications: - email: - recipients: - - sebastien.jourdain@kitware.com - on_success: change - on_failure: always - -addons: - chrome: stable - -node_js: - - '10' - -cache: - directories: - - "$HOME/.npm" - - documentation/build-tmp - -script: - - npm run build:release - - git config --global user.name "Travis CI" - - git config --global user.email "sebastien.jourdain@kitware.com" - - export GIT_PUBLISH_URL=https://${GH_TOKEN}@github.com/Kitware/visualizer.git - - if [ "$TRAVIS_BRANCH" == "master" ]; then npm run doc:publish; fi - -after_success: - - npm run semantic-release - -branches: - except: - - "/^v\\d+\\.\\d+\\.\\d+$/"