Skip to content

Commit

Permalink
Обновил workflow для создания релиза
Browse files Browse the repository at this point in the history
  • Loading branch information
Merzlikin-Matvey committed Sep 22, 2024
1 parent 29cd1fc commit 258fd36
Showing 1 changed file with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,14 @@ jobs:
echo "NEW_VERSION=false" >> $GITHUB_ENV
fi
- name: Build package
if: env.NEW_VERSION == 'true'
run: |
poetry build
- name: Create new release
if: env.NEW_VERSION == 'true'
id: create_release
uses: actions/create-release@v1
with:
tag_name: ${{ env.VERSION }}
Expand All @@ -53,5 +59,16 @@ jobs:
New release ${{ env.VERSION }}
draft: false
prerelease: false
env:
GITHUB_TOKEN: ${{ secrets.REPO_ACCESS_TOKEN }}

- name: Upload release asset
if: env.NEW_VERSION == 'true'
uses: actions/upload-release-asset@v1
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: ./dist/your-package-name-${{ env.VERSION }}.tar.gz
asset_name: your-package-name-${{ env.VERSION }}.tar.gz
asset_content_type: application/gzip
env:
GITHUB_TOKEN: ${{ secrets.REPO_ACCESS_TOKEN }}

0 comments on commit 258fd36

Please sign in to comment.