forked from opencepk/opencepk-template-base
-
Notifications
You must be signed in to change notification settings - Fork 2
35 lines (35 loc) · 1.24 KB
/
git-upstream-set.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
---
name: git-upstream-set
on:
pull_request:
types: [opened, synchronize]
jobs:
git-upstream-set-create-pr:
runs-on: ubuntu-latest
steps:
- name: checkout
uses: actions/checkout@v4
- name: Extract branch name
id: extract_branch
env:
HEAD_REF: ${{ github.head_ref }}
run: echo "BRANCH_NAME=${HEAD_REF}" >> "${GITHUB_ENV}"
- name: create PR
uses: opencepk/opencepk-module-ghactions-common/git-upstream-set-create-pr@main
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
excluded-repos: "opencepk/opencepk-template-base,anythingInFuture/repo-to-exclude"
upstream-file-path: ".github/UPSTREAM"
new-branch-name: "add-upstream-file-bot"
bot-commit-message: "Automatically add UPSTREAM file since it does not exists"
github-current-branch: ${{ env.BRANCH_NAME }}
git-upstream-set-check-pr-block:
needs: git-upstream-set-create-pr
runs-on: ubuntu-latest
steps:
- name: checkout
uses: actions/checkout@v4
- name: Check for PR Blockage
uses: opencepk/opencepk-module-ghactions-common/git-upstream-set-check-pr-block@main
with:
github-token: ${{ secrets.GITHUB_TOKEN }}