1
0
mirror of https://github.com/kremalicious/gatsby-plugin-matomo.git synced 2024-12-22 09:13:19 +01:00

CI tweaks

This commit is contained in:
Matthias Kretschmann 2021-02-01 00:03:55 +01:00
parent 403092eff7
commit 8e620750dc
Signed by: m
GPG Key ID: 606EEEF3C479A91F
3 changed files with 39 additions and 25 deletions

View File

@ -1,8 +1,7 @@
version: 2 version: 2
updates: updates:
- package-ecosystem: npm - package-ecosystem: npm
directory: "/" directory: '/'
schedule: schedule:
interval: daily interval: weekly
time: '04:00' time: '04:00'
open-pull-requests-limit: 10

View File

@ -1,29 +1,44 @@
name: 'CI/CD Pipeline' name: 'CI/CD Pipeline'
on: [push] on:
push:
branches:
- main
pull_request:
branches:
- '**'
jobs: jobs:
test: test:
runs-on: ubuntu-latest runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
node: ['14']
steps: steps:
- uses: actions/checkout@v2 - uses: actions/checkout@v2
- uses: actions/setup-node@v2
with:
node-version: ${{ matrix.node }}
- uses: actions/setup-node@v1 - run: npm ci
with: - run: npm test
node-version: '13.x' - run: npm run build
- uses: actions/cache@v1
with:
path: ~/.npm
key: ${{ runner.os }}-node
- run: npm install coverage:
- name: Run tests & publish code coverage runs-on: ubuntu-latest
uses: paambaati/codeclimate-action@v2.4.0 steps:
with: - uses: actions/checkout@v2
coverageCommand: npm test - uses: actions/setup-node@v2
- run: npm ci
- uses: paambaati/codeclimate-action@v2.7.5
env: env:
CC_TEST_REPORTER_ID: ${{ secrets.CC_TEST_REPORTER_ID }} CC_TEST_REPORTER_ID: ${{ secrets.CC_TEST_REPORTER_ID }}
with:
coverageCommand: npm test
publish: publish:
needs: test needs: test
@ -31,17 +46,16 @@ jobs:
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- uses: actions/checkout@v2 - uses: actions/checkout@v2
- uses: actions/setup-node@v1 - uses: actions/setup-node@v2
with: with:
node-version: '13.x'
registry-url: 'https://registry.npmjs.org' registry-url: 'https://registry.npmjs.org'
- run: npm install
- run: npm ci
- run: npm publish - run: npm publish
env: env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
# - uses: actions/setup-node@v1 # - uses: actions/setup-node@v1
# with: # with:
# node-version: '13.x'
# registry-url: 'https://npm.pkg.github.com' # registry-url: 'https://npm.pkg.github.com'
# - run: npm publish # - run: npm publish
# env: # env:

View File

@ -2,5 +2,6 @@
"semi": false, "semi": false,
"singleQuote": true, "singleQuote": true,
"trailingComma": "none", "trailingComma": "none",
"tabWidth": 2 "tabWidth": 2,
"endOfLine": "auto"
} }