diff --git a/.github/workflows/deploy-job.yml b/.github/workflows/deploy-job.yml index 4a65d52..4db3e3b 100644 --- a/.github/workflows/deploy-job.yml +++ b/.github/workflows/deploy-job.yml @@ -63,8 +63,8 @@ jobs: id: verify-changed-files with: files: | - src/**/*.py - setup.cfg + src/**/*.py + setup.cfg - name: Download artifacts if: steps.verify-changed-files.outputs.files_changed == 'true' uses: actions/download-artifact@v3 @@ -82,3 +82,25 @@ jobs: uses: pypa/gh-action-pypi-publish@release/v1 with: password: ${{ secrets.PYPI_API_TOKEN }} + release: + runs-on: ubuntu-latest + if: github.ref == 'refs/heads/main' + needs: deploy + steps: + - uses: actions/checkout@v3 + - name: Set version release + run: | + VER=$(cat setup.cfg | grep version | cut -d "=" -f 2 | xargs) + COMMIT_MESSAGE=$(git log -1 --pretty=%B) + echo "RELEASE_VERSION=$VER" >> $GITHUB_ENV + echo "COMMIT_MESSAGE=$COMMIT_MESSAGE" >> $GITHUB_ENV + - name: Create release + uses: actions/create-release@v1 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + tag_name: ${{ env.RELEASE_VERSION }} + release_name: v${{ env.RELEASE_VERSION }} + body: ${{ env.COMMIT_MESSAGE }} + draft: false + prerelease: false diff --git a/setup.cfg b/setup.cfg index 3bec01a..a4ca236 100644 --- a/setup.cfg +++ b/setup.cfg @@ -11,6 +11,7 @@ url = https://github.com/paveldat/God-s-eye [options] package_dir = =src + packages = clickjacking dns_lookup @@ -24,6 +25,7 @@ packages = ip_info_finder pwned phone_info + install_requires = requests >= 2.25.1 dnspython >= 2.2.1