fix warning #3
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: Nightly | |
on: | |
push: | |
branches: | |
- 'master' | |
jobs: | |
nightly: | |
name: Deploy nightly | |
strategy: | |
fail-fast: false | |
matrix: | |
os: [ubuntu-latest, windows-latest, macOS-latest] | |
env: | |
CC: gcc | |
runs-on: ${{ matrix.os }} | |
if: "!contains(github.event.head_commit.message, '[skip ci]')" | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Build | |
run: make | |
- name: Build asset | |
run: | | |
strip mdr* | |
7z a mdr-nightly.zip mdr* | |
- name: Set tag | |
if: ${{ matrix.os == 'ubuntu-latest' }} | |
run: | | |
git config --local user.email "action@github.com" | |
git config --local user.name "GitHub Action" | |
git tag -f -a nightly -m "Nightly update" | |
git push origin -f --follow-tags nightly | |
- name: Deploy release | |
uses: WebFreak001/deploy-nightly@v1.1.0 | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
with: | |
upload_url: https://uploads.github.com/repos/fennecdjay/mdr/releases/40889237/assets{?name,label} | |
release_id: 40889237 # same as above (id can just be taken out the upload_url, it's used to find old releases) | |
asset_path: ./mdr-nightly.zip # path to archive to upload | |
asset_name: mdr-nightly-${{matrix.os}}-$$.zip # name to upload the release as, use $$ to insert date (YYYYMMDD) and 6 letter commit hash | |
asset_content_type: application/zip # required by GitHub API | |
max_releases: 1 # optional, if there are more releases than this matching the asset_name, the oldest ones are going to be deleted |