mirror of
https://github.com/LizardByte/Sunshine.git
synced 2025-02-05 15:39:50 +00:00
ci: update global workflows
This commit is contained in:
parent
8164c09ea0
commit
4d3c9b0be8
1
.github/dependabot.yml
vendored
1
.github/dependabot.yml
vendored
@ -1,3 +1,4 @@
|
|||||||
|
---
|
||||||
# This action is centrally managed in https://github.com/<organization>/.github/
|
# This action is centrally managed in https://github.com/<organization>/.github/
|
||||||
# Don't make changes to this file in this repo as they will be overwritten with changes made to the same file in
|
# Don't make changes to this file in this repo as they will be overwritten with changes made to the same file in
|
||||||
# the above-mentioned repo.
|
# the above-mentioned repo.
|
||||||
|
1
.github/label-actions.yml
vendored
1
.github/label-actions.yml
vendored
@ -1,3 +1,4 @@
|
|||||||
|
---
|
||||||
# This action is centrally managed in https://github.com/<organization>/.github/
|
# This action is centrally managed in https://github.com/<organization>/.github/
|
||||||
# Don't make changes to this file in this repo as they will be overwritten with changes made to the same file in
|
# Don't make changes to this file in this repo as they will be overwritten with changes made to the same file in
|
||||||
# the above-mentioned repo.
|
# the above-mentioned repo.
|
||||||
|
8
.github/workflows/auto-create-pr.yml
vendored
8
.github/workflows/auto-create-pr.yml
vendored
@ -1,3 +1,4 @@
|
|||||||
|
---
|
||||||
# This action is centrally managed in https://github.com/<organization>/.github/
|
# This action is centrally managed in https://github.com/<organization>/.github/
|
||||||
# Don't make changes to this file in this repo as they will be overwritten with changes made to the same file in
|
# Don't make changes to this file in this repo as they will be overwritten with changes made to the same file in
|
||||||
# the above-mentioned repo.
|
# the above-mentioned repo.
|
||||||
@ -5,15 +6,12 @@
|
|||||||
name: Auto create PR
|
name: Auto create PR
|
||||||
|
|
||||||
on:
|
on:
|
||||||
pull_request:
|
push:
|
||||||
types:
|
|
||||||
- closed
|
|
||||||
branches:
|
branches:
|
||||||
- 'nightly'
|
- 'nightly'
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
create_pr:
|
create_pr:
|
||||||
if: github.event.pull_request.merged == true
|
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
@ -25,7 +23,7 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
source_branch: "" # should be "nightly" as it's the triggering branch
|
source_branch: "" # should be "nightly" as it's the triggering branch
|
||||||
destination_branch: "master"
|
destination_branch: "master"
|
||||||
pr_title: "Pulling ${{ github.ref }} into master"
|
pr_title: "Pulling ${{ github.ref_name }} into master"
|
||||||
pr_template: ".github/pr_release_template.md"
|
pr_template: ".github/pr_release_template.md"
|
||||||
pr_assignee: "${{ secrets.GH_BOT_NAME }}"
|
pr_assignee: "${{ secrets.GH_BOT_NAME }}"
|
||||||
pr_draft: true
|
pr_draft: true
|
||||||
|
31
.github/workflows/automerge.yml
vendored
31
.github/workflows/automerge.yml
vendored
@ -1,3 +1,4 @@
|
|||||||
|
---
|
||||||
# This action is centrally managed in https://github.com/<organization>/.github/
|
# This action is centrally managed in https://github.com/<organization>/.github/
|
||||||
# Don't make changes to this file in this repo as they will be overwritten with changes made to the same file in
|
# Don't make changes to this file in this repo as they will be overwritten with changes made to the same file in
|
||||||
# the above-mentioned repo.
|
# the above-mentioned repo.
|
||||||
@ -17,22 +18,22 @@ jobs:
|
|||||||
contains(fromJson('["LizardByte-bot"]'), github.actor)
|
contains(fromJson('["LizardByte-bot"]'), github.actor)
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- name: Autoapproving
|
- name: Autoapproving
|
||||||
uses: hmarr/auto-approve-action@v2
|
uses: hmarr/auto-approve-action@v2
|
||||||
with:
|
with:
|
||||||
github-token: "${{ secrets.GITHUB_TOKEN }}"
|
github-token: "${{ secrets.GITHUB_TOKEN }}"
|
||||||
|
|
||||||
- name: Label autoapproved
|
- name: Label autoapproved
|
||||||
uses: actions/github-script@v5
|
uses: actions/github-script@v6
|
||||||
with:
|
with:
|
||||||
github-token: ${{ secrets.GH_BOT_TOKEN }}
|
github-token: ${{ secrets.GH_BOT_TOKEN }}
|
||||||
script: |
|
script: |
|
||||||
github.rest.issues.addLabels({
|
github.rest.issues.addLabels({
|
||||||
issue_number: context.issue.number,
|
issue_number: context.issue.number,
|
||||||
owner: context.repo.owner,
|
owner: context.repo.owner,
|
||||||
repo: context.repo.repo,
|
repo: context.repo.repo,
|
||||||
labels: ['autoapproved', 'autoupdate']
|
labels: ['autoapproved', 'autoupdate']
|
||||||
})
|
})
|
||||||
|
|
||||||
automerge:
|
automerge:
|
||||||
needs: [autoapprove]
|
needs: [autoapprove]
|
||||||
|
32
.github/workflows/autoupdate.yml
vendored
Normal file
32
.github/workflows/autoupdate.yml
vendored
Normal file
@ -0,0 +1,32 @@
|
|||||||
|
---
|
||||||
|
# This action is centrally managed in https://github.com/<organization>/.github/
|
||||||
|
# Don't make changes to this file in this repo as they will be overwritten with changes made to the same file in
|
||||||
|
# the above-mentioned repo.
|
||||||
|
|
||||||
|
# This workflow is designed to work with:
|
||||||
|
# - automerge workflows
|
||||||
|
|
||||||
|
# It uses GitHub Action that auto-updates pull requests branches, when changes are pushed to their destination branch.
|
||||||
|
# Auto-updating to the latest destination branch works only in the context of upstream repo and not forks.
|
||||||
|
|
||||||
|
name: autoupdate
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches:
|
||||||
|
- 'nightly'
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
autoupdate-for-bot:
|
||||||
|
name: Autoupdate autoapproved PR created in the upstream
|
||||||
|
if: startsWith(github.repository, 'LizardByte/')
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: Update
|
||||||
|
uses: docker://chinthakagodawita/autoupdate-action:v1
|
||||||
|
env:
|
||||||
|
GITHUB_TOKEN: '${{ secrets.GH_BOT_TOKEN }}'
|
||||||
|
PR_FILTER: "labelled"
|
||||||
|
PR_LABELS: "autoupdate"
|
||||||
|
PR_READY_STATE: "ready_for_review"
|
||||||
|
MERGE_CONFLICT_ACTION: "ignore"
|
1
.github/workflows/issues-stale.yml
vendored
1
.github/workflows/issues-stale.yml
vendored
@ -1,3 +1,4 @@
|
|||||||
|
---
|
||||||
# This action is centrally managed in https://github.com/<organization>/.github/
|
# This action is centrally managed in https://github.com/<organization>/.github/
|
||||||
# Don't make changes to this file in this repo as they will be overwritten with changes made to the same file in
|
# Don't make changes to this file in this repo as they will be overwritten with changes made to the same file in
|
||||||
# the above-mentioned repo.
|
# the above-mentioned repo.
|
||||||
|
3
.github/workflows/issues.yml
vendored
3
.github/workflows/issues.yml
vendored
@ -1,3 +1,4 @@
|
|||||||
|
---
|
||||||
# This action is centrally managed in https://github.com/<organization>/.github/
|
# This action is centrally managed in https://github.com/<organization>/.github/
|
||||||
# Don't make changes to this file in this repo as they will be overwritten with changes made to the same file in
|
# Don't make changes to this file in this repo as they will be overwritten with changes made to the same file in
|
||||||
# the above-mentioned repo.
|
# the above-mentioned repo.
|
||||||
@ -8,7 +9,7 @@ on:
|
|||||||
issues:
|
issues:
|
||||||
types: [labeled, unlabeled]
|
types: [labeled, unlabeled]
|
||||||
discussion:
|
discussion:
|
||||||
types: [ labeled, unlabeled ]
|
types: [labeled, unlabeled]
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
label:
|
label:
|
||||||
|
3
.github/workflows/pull-requests.yml
vendored
3
.github/workflows/pull-requests.yml
vendored
@ -1,3 +1,4 @@
|
|||||||
|
---
|
||||||
# This action is centrally managed in https://github.com/<organization>/.github/
|
# This action is centrally managed in https://github.com/<organization>/.github/
|
||||||
# Don't make changes to this file in this repo as they will be overwritten with changes made to the same file in
|
# Don't make changes to this file in this repo as they will be overwritten with changes made to the same file in
|
||||||
# the above-mentioned repo.
|
# the above-mentioned repo.
|
||||||
@ -18,7 +19,7 @@ jobs:
|
|||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
with:
|
with:
|
||||||
target: master
|
target: master
|
||||||
exclude: nightly # Don't prevent going from nightly -> master
|
exclude: nightly # Don't prevent going from nightly -> master
|
||||||
change-to: nightly
|
change-to: nightly
|
||||||
comment: |
|
comment: |
|
||||||
Your PR was set to `master`, PRs should be sent to `nightly`.
|
Your PR was set to `master`, PRs should be sent to `nightly`.
|
||||||
|
46
.github/workflows/yaml-lint.yml
vendored
Normal file
46
.github/workflows/yaml-lint.yml
vendored
Normal file
@ -0,0 +1,46 @@
|
|||||||
|
---
|
||||||
|
# This action is centrally managed in https://github.com/<organization>/.github/
|
||||||
|
# Don't make changes to this file in this repo as they will be overwritten with changes made to the same file in
|
||||||
|
# the above-mentioned repo.
|
||||||
|
|
||||||
|
name: yaml lint
|
||||||
|
|
||||||
|
on:
|
||||||
|
pull_request:
|
||||||
|
branches: [master, nightly]
|
||||||
|
types: [opened, synchronize, reopened]
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
yaml-lint:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: Checkout
|
||||||
|
uses: actions/checkout@v2
|
||||||
|
|
||||||
|
- name: yaml lint
|
||||||
|
id: yaml-lint
|
||||||
|
uses: ibiqlik/action-yamllint@v3
|
||||||
|
with:
|
||||||
|
# https://yamllint.readthedocs.io/en/stable/configuration.html#default-configuration
|
||||||
|
config_data: |
|
||||||
|
extends: default
|
||||||
|
rules:
|
||||||
|
comments:
|
||||||
|
level: error
|
||||||
|
line-length:
|
||||||
|
max: 120
|
||||||
|
truthy:
|
||||||
|
allowed-values: ['true', 'false', 'on'] # GitHub uses "on" for workflow event triggers
|
||||||
|
check-keys: true
|
||||||
|
level: error
|
||||||
|
|
||||||
|
- name: Log
|
||||||
|
run: |
|
||||||
|
echo ${{ steps.yaml-lint.outputs.logfile }}
|
||||||
|
|
||||||
|
- name: Upload logs
|
||||||
|
uses: actions/upload-artifact@v2
|
||||||
|
if: failure()
|
||||||
|
with:
|
||||||
|
name: yamllint-logfile
|
||||||
|
path: ${{ steps.yaml-lint.outputs.logfile }}
|
Loading…
x
Reference in New Issue
Block a user