feat(repo): Modify github on push
- Close all PR - Add mirror information in README.md
This commit is contained in:
28
.github/workflows/rewrite-readme.yaml
vendored
Normal file
28
.github/workflows/rewrite-readme.yaml
vendored
Normal file
@@ -0,0 +1,28 @@
|
|||||||
|
name: Set README on GitHub
|
||||||
|
|
||||||
|
# Trigger this workflow every 12 hours.
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches:
|
||||||
|
- "**"
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
rewrite_readme:
|
||||||
|
name: Append header on README
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
if: contains(github.server_url, 'github.com')
|
||||||
|
permissions:
|
||||||
|
contents: write
|
||||||
|
steps:
|
||||||
|
- name: Write header
|
||||||
|
run: |
|
||||||
|
cp README.md __OLD.md
|
||||||
|
echo "> This repository is a mirror of [repo.katenary.io](https://repo.katenary.io/katenary/katenary)" > README.md
|
||||||
|
echo >> README.md
|
||||||
|
cat __OLD.md >> README.md
|
||||||
|
- name: Commit
|
||||||
|
uses: EndBug/add-and-commit@v9
|
||||||
|
with:
|
||||||
|
add: README.md
|
||||||
|
message: "Add mirror information"
|
||||||
|
push: true
|
28
.github/workflows/stale.yaml
vendored
Normal file
28
.github/workflows/stale.yaml
vendored
Normal file
@@ -0,0 +1,28 @@
|
|||||||
|
# Thanks to blender authors to provide this.
|
||||||
|
# Adaptation made for Katenary
|
||||||
|
|
||||||
|
name: Close GitHub Pull Requests
|
||||||
|
|
||||||
|
# Trigger this workflow every 12 hours.
|
||||||
|
on:
|
||||||
|
schedule:
|
||||||
|
- cron: "* */12 * * *"
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
close_prs:
|
||||||
|
name: Close Pull Requests
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
if: contains(github.server_url, 'github.com')
|
||||||
|
permissions:
|
||||||
|
pull-requests: write
|
||||||
|
steps:
|
||||||
|
- uses: actions/stale@v9
|
||||||
|
with:
|
||||||
|
# Number of days before a pull request is marked as stale.
|
||||||
|
days-before-pr-stale: 0
|
||||||
|
# Number of days before a pull request is closed.
|
||||||
|
days-before-pr-close: 0
|
||||||
|
# Message posted when closing a pull request.
|
||||||
|
stale-pr-message: |
|
||||||
|
This pull request has been automatically closed because this repository is a read-only mirror.
|
||||||
|
Katenary developement happens on [repo.katenary.io](https://repo.katenary.io/Katenary/katenary).
|
Reference in New Issue
Block a user