Build and Push #70
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 and Push | |
on: workflow_dispatch | |
jobs: | |
android: | |
uses: ./.github/workflows/android.yml | |
ios: | |
uses: ./.github/workflows/ios.yml | |
linux: | |
uses: ./.github/workflows/linux.yml | |
mac: | |
uses: ./.github/workflows/mac.yml | |
windows: | |
uses: ./.github/workflows/windows.yml | |
miscellaneous: | |
uses: ./.github/workflows/miscellaneous.yml | |
publisher: | |
needs: [android, ios, linux, mac, windows, miscellaneous] | |
runs-on: ubuntu-latest | |
permissions: | |
contents: write | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
with: | |
ref: ${{ github.ref_name }} | |
- name: Delete old NDLL's | |
run: rm -rf ndll | |
- name: Download all artifacts | |
uses: actions/download-artifact@v4 | |
with: | |
path: . | |
merge-multiple: true | |
- name: Push to GitHub | |
run: | | |
USER_INFO=$(curl -s "https://api.github.com/users/${{ github.actor }}") | |
USERID=$(echo "$USER_INFO" | jq -r '.id') | |
USERNAME=$(echo "$USER_INFO" | jq -r '.name') | |
git config --local user.email "[email protected]" | |
git config --local user.name "GitHub Actions" | |
git add ndll | |
git add tools/tools.n | |
git add run.n | |
git add svg.n | |
# git add templates/bin/lime.exe | |
git commit --author="${USERNAME} <${USERID}+$(echo "$USERNAME" | sed 's/ /-/g')@users.noreply.github.com>" -m "Built and Pushed New NDLL's." || { | |
echo "Didn't commit anything, skipping git push." | |
exit 0 | |
} | |
git push |