Merge pull request #345 from Luni-4/cargo-publish

Allow cargo-publish failure
This commit is contained in:
est31 2019-11-15 10:55:45 +01:00 committed by GitHub
commit 6fafc54dc7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 24 additions and 4 deletions

View File

@ -28,19 +28,39 @@ jobs:
if: github.event_name == 'push' && github.ref == 'refs/heads/master' if: github.event_name == 'push' && github.ref == 'refs/heads/master'
env:
CRATESIO_TOKEN: ${{ secrets.CRATESIO_TOKEN }}
ALSA: alsa-sys.txt
CPAL: cpal.txt
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- uses: actions/checkout@v1 - uses: actions/checkout@v1
- name: Install alsa - name: Install alsa
run: sudo apt-get install libasound2-dev run: sudo apt-get install libasound2-dev
- name: Run cargo publish - name: Run cargo publish for alsa-sys
continue-on-error: true
env: env:
MANIFEST: alsa-sys/Cargo.toml MANIFEST: alsa-sys/Cargo.toml
CRATESIO_TOKEN: ${{ secrets.CRATESIO_TOKEN }}
run: | run: |
cargo publish --token $CRATESIO_TOKEN --manifest-path $MANIFEST cargo publish --token $CRATESIO_TOKEN --manifest-path $MANIFEST 2> $ALSA
cargo publish --token $CRATESIO_TOKEN - name: Check if alsa-sys is already published
run: |
empty=0
grep -q '[^[:space:]]' < $ALSA || empty=1
[ $empty -eq 0 ] && cat $ALSA
[ $empty -eq 1 ] || grep -q "is already uploaded" < $ALSA
- name: Run cargo publish for cpal
continue-on-error: true
run: |
cargo publish --token $CRATESIO_TOKEN 2> $CPAL
- name: Check if cpal is already published
run: |
empty=0
grep -q '[^[:space:]]' < $CPAL || empty=1
[ $empty -eq 0 ] && cat $CPAL
[ $empty -eq 1 ] || grep -q "is already uploaded" < $CPAL
ubuntu-test: ubuntu-test: