fastasyncvoxelsniper 3.2.1 #111
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: build | |
on: | |
pull_request: | |
branches: [ "master" ] | |
# Allows you to run this workflow manually from the Actions tab | |
workflow_dispatch: | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Checkout PR | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
run: | | |
gh pr checkout ${{ github.event.pull_request.number }} | |
git config --local user.email "[email protected]" | |
git config --local user.name "Reproducible Central CI" | |
- name: Install dos2unix | |
run: sudo apt-get install -y dos2unix | |
- name: List changed files | |
id: changed-files | |
uses: tj-actions/changed-files@v45 | |
- name: Build from buildspec | |
run: | | |
for file in ${{ steps.changed-files.outputs.all_changed_files }}; do | |
if [[ $file == *.buildspec ]]; then | |
./rebuild.sh $file | |
bin/update-project-summary.sh "$(dirname $file)" | |
git add "$(dirname $file)" | |
git commit -m "./rebuild.sh $file" | |
git push | |
. $file | |
buildcompare="$(basename $buildinfo .buildinfo).buildcompare" | |
grep -v okFiles "$(dirname $file)/$buildcompare" >> buildcompare.txt | |
fi | |
done | |
- name: Add PR comment with results | |
uses: mshick/add-pr-comment@v2 | |
with: | |
message-path: | | |
buildcompare.txt | |
preformatted: true | |
- name: Merge PR | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
run: | | |
if [ $(grep "ko=0" buildcompare.txt | wc -l) -eq 1 ] | |
then | |
gh pr merge -m -d | |
fi |