I want to trigger my GitHub ci after merge request get merged. because i want to ship my source from GitHub to gitlab after merge request merged in GitHub
Example - https://github.com/kumaresan-subramani/ej2-blaz-doc/pull/7
CI getting triggered once pull request getting created, but after merge it won't trigger CI so that I am not able to ship my source from github to gitlab
My yml file :
name: Node.js CI
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
types: [opened, closed]
jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [10.x]
steps:
- uses: actions/checkout@v2
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
- name: set environment variables
uses: allenevans/set-env@v1.0.0
with:
MY_ENV_VAR: 'my value'
GIT_USER: ${{ secrets.USER }}
GIT_TOKEN: ${{ secrets.TOKEN }}
- name: Install
run: npm i
- name: Publish
run: npm run publish
if: github.event.pull_request.merged == 'true'
