feature: Allow to skip ci using commit message

This commit is contained in:
Rodrigo Fernandes 2020-01-01 20:08:20 +00:00
parent 88ce8e31ca
commit a04aa652d9
No known key found for this signature in database
GPG key ID: 67157D2E3D4258B4
3 changed files with 8 additions and 3 deletions

View file

@ -4,6 +4,7 @@ on: [push]
jobs:
build:
if: "!contains(github.event.head_commit.message, 'skip ci')"
runs-on: ubuntu-18.04
env:
CI: true

View file

@ -8,12 +8,14 @@ on:
jobs:
version:
if:
github.event.pull_request.merged && "!contains(github.event.head_commit.message, 'skip ci')" &&
"!contains(github.event.head_commit.message, 'skip release')"
runs-on: ubuntu-18.04
container:
image: codacy/git-version
steps:
- uses: actions/checkout@v1
if: github.event.pull_request.merged
- name: Configure Git
run: |
git checkout -f "${GITHUB_REF#refs/heads/}"
@ -107,7 +109,7 @@ jobs:
with:
node-version: 13
registry-url: https://npm.pkg.github.com
scope: "@rtfpessoa"
scope: '@rtfpessoa'
- name: Publish to GitHub
env:
NODE_AUTH_TOKEN: ${{secrets.GITHUB_TOKEN}}

View file

@ -8,6 +8,9 @@ on:
jobs:
build:
if:
github.event.pull_request.merged && "!contains(github.event.head_commit.message, 'skip ci')" &&
"!contains(github.event.head_commit.message, 'skip release')"
runs-on: ubuntu-18.04
env:
CI: true
@ -16,7 +19,6 @@ jobs:
node-version: [13.x]
steps:
- uses: actions/checkout@v1
if: github.event.pull_request.merged
- name: Setup Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with: