update cd.yml

This commit is contained in:
Sunshine 2020-04-04 22:12:35 -04:00
parent cf3a8c8ede
commit d4d9bbe424
No known key found for this signature in database
GPG Key ID: B80CA68703CD8AB1
1 changed files with 21 additions and 0 deletions

21
.github/workflows/cd.yml vendored Normal file
View File

@ -0,0 +1,21 @@
name: CD
on:
release:
types: [created]
jobs:
publish:
runs-on: windows-latest
steps:
- name: Checkout the repository
uses: actions/checkout@master
- name: Generate artifacts
run: cargo build --all --locked
- name: Upload artifacts
env:
GITHUB_DEPLOY_TOKEN: ${{ secrets.GITHUB_DEPLOY_TOKEN }}
run: |
curl -sSL -XPOST -H "Authorization: token ${GITHUB_DEPLOY_TOKEN}" --upload-file D:\a\test-repo\test-repo\target\debug\deps\test-*.exe" --header "Content-Type:application/octet-stream" --write-out "%{http_code}" "https://uploads.github.com/repos/Y2Z/test-repo/releases/latest/assets?name=test.exe"