diff --git a/.github/workflows/update-main-conf.yml b/.github/workflows/update-main-conf.yml index 2219a5d..5549d67 100644 --- a/.github/workflows/update-main-conf.yml +++ b/.github/workflows/update-main-conf.yml @@ -1,6 +1,9 @@ -name: Update main.conf in PR +name: Update main.conf on: + push: + branches-ignore: + - main pull_request_target: types: - opened @@ -15,11 +18,16 @@ permissions: jobs: update-main-conf: - if: github.event.pull_request.head.repo.full_name == github.repository + if: github.event_name == 'push' || github.event.pull_request.head.repo.full_name == github.repository runs-on: ubuntu-latest steps: + - name: Check out branch + if: github.event_name == 'push' + uses: actions/checkout@v4 + - name: Check out PR branch + if: github.event_name == 'pull_request_target' uses: actions/checkout@v4 with: repository: ${{ github.event.pull_request.head.repo.full_name }} @@ -90,7 +98,15 @@ jobs: print('Updated main.conf') PY - - name: Commit updated main.conf + - name: Commit updated main.conf on branch + if: github.event_name == 'push' + uses: stefanzweifel/git-auto-commit-action@v5 + with: + commit_message: "chore: update generated main.conf" + file_pattern: main.conf + + - name: Commit updated main.conf on PR branch + if: github.event_name == 'pull_request_target' uses: stefanzweifel/git-auto-commit-action@v5 with: commit_message: "chore: update generated main.conf" diff --git a/README.md b/README.md index 9c331c4..de2ea87 100644 --- a/README.md +++ b/README.md @@ -6,7 +6,7 @@ This is a collection of all messages that are displayed in the server list. The ## Pull requests -We accept your submissions! You may clone this repository, add a new line in [edit-me.txt](edit-me.txt) and create a pull request in . +We accept your submissions! You may fork this repository, add a new line in [edit-me.txt](edit-me.txt) and create a pull request in . When the pull request gets approved, Github will update [main.conf](main.conf) to match [edit-me.txt](edit-me.txt). @@ -19,7 +19,8 @@ To avoid controversy or inappropriate sentences, the guideline rules below will ## How to contribute -- Clone project using `git clone https://github.com/BorderMC/motd.git` +- Fork this repository +- Clone your fork using `git clone https://github.com//motd.git` - Read [the rules](#rules) - Edit [edit-me.txt](edit-me.txt) - Make a branch with `git branch /` for example `git branch pernio/nether-reset-info` diff --git a/edit-me.txt b/edit-me.txt index bc266cf..642640f 100644 --- a/edit-me.txt +++ b/edit-me.txt @@ -18,4 +18,7 @@ This message has been claimed Server has not collapsed yet Probably stable Please remain inside the borders -Nothing personal, just geopolitics \ No newline at end of file +Nothing personal, just geopolitics +We have wool +Non earthy +Nothing personal, just geopolitics diff --git a/main.conf b/main.conf index 2b7a747..b01e4ff 100644 --- a/main.conf +++ b/main.conf @@ -75,6 +75,56 @@ motds=[ line1="BorderMC" line2="Beyond the border" icon=random + }, + { + line1="BorderMC" + line2="Have you tried turning it off and on again?" + icon=random + }, + { + line1="BorderMC" + line2="We take no responsibility" + icon=random + }, + { + line1="BorderMC" + line2="This message has been claimed" + icon=random + }, + { + line1="BorderMC" + line2="Server has not collapsed yet" + icon=random + }, + { + line1="BorderMC" + line2="Probably stable" + icon=random + }, + { + line1="BorderMC" + line2="Please remain inside the borders" + icon=random + }, + { + line1="BorderMC" + line2="Nothing personal, just geopolitics" + icon=random + }, + { + line1="BorderMC" + line2="We have wool" + icon=random + }, + { + line1="BorderMC" + line2="Non earthy" + icon=random + }, + { + line1="BorderMC" + line2="Nothing personal, just geopolitics" + icon=random } ]