freetube/.github/workflows/autoMerge.yml

25 lines
870 B
YAML
Raw Normal View History

2021-08-20 01:18:15 +00:00
name: Auto Merge PR
2021-08-19 21:28:39 +00:00
# Controls when the workflow will run
on:
2021-08-20 01:18:15 +00:00
# Triggers the workflow on push or pull request events but only for the development branch
2021-08-20 02:05:47 +00:00
pull_request:
types: [opened, synchronize, reopened]
2021-08-19 21:28:39 +00:00
2021-08-20 01:18:15 +00:00
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
2021-08-19 21:28:39 +00:00
jobs:
2021-08-20 01:18:15 +00:00
# This workflow contains a single job called "build"
2021-08-19 21:28:39 +00:00
build:
# The type of runner that the job will run on
2021-08-20 03:17:35 +00:00
runs-on: ubuntu-latest
2021-08-20 03:33:25 +00:00
environment: workflow_env
2021-08-19 21:28:39 +00:00
# Steps represent a sequence of tasks that will be executed as part of the job
steps:
2021-08-20 02:44:07 +00:00
- name: Enable Auto Merge
2021-08-20 02:23:53 +00:00
run: |
2021-08-20 03:31:38 +00:00
echo ${{ secrets.MERGE_TOKEN }} >> auth.txt
2021-08-20 03:17:35 +00:00
gh auth login --with-token < auth.txt
2021-08-20 03:17:48 +00:00
rm auth.txt
gh pr merge https://github.com/FreeTubeApp/FreeTube/pull/${{ github.event.pull_request.number }} --auto