From d4d9bbe4244a6755045f4418e6790429e2393c48 Mon Sep 17 00:00:00 2001 From: Sunshine Date: Sat, 4 Apr 2020 22:12:35 -0400 Subject: [PATCH] update cd.yml --- .github/workflows/cd.yml | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 .github/workflows/cd.yml diff --git a/.github/workflows/cd.yml b/.github/workflows/cd.yml new file mode 100644 index 0000000..1ae704f --- /dev/null +++ b/.github/workflows/cd.yml @@ -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"