name: Analyze code and publish script on: push: branches: - "main" paths: - "cdl_downloader**" jobs: analyze: steps: - name: Checkout uses: actions/checkout@v6 - name: Go to app directory run: cd cdl_downloader - name: Set up Python uses: actions/setup-python@v6 with: python-version: "3.10" - name: Install dependencies run: | python -m pip install --upgrade pip pip install -r requirements.txt pip install pylint - name: Analysing the code with pylint run: pylint --exit-zero $(git ls-files '*.py') publish: steps: - name: Checkout uses: actions/checkout@v6.0.2 with: fetch-depth: 0 - name: Setup GitVersion uses: gittools/actions/gitversion/setup@v4.2.0 with: versionSpec: 6.4.x - name: Determine version uses: gittools/actions/gitversion/execute@v4.2.0 id: gitversion with: configFilePath: ./.gitea/config/gitversion.yml - name: Create .TAR.GZ archive uses: ksm2/archive-action@v1 with: format: "tar.gz" name: cdl_downloader_${{steps.gitversion.outputs.SemVer}} include: "./cdl_downloader" - name: Create .ZIP archive uses: ksm2/archive-action@v1 with: format: "zip" name: cdl_downloader_${{steps.gitversion.outputs.SemVer}} include: "./cdl_downloader" - name: Create Release uses: akkuman/gitea-release-action@v1 with: tag_name: ${{steps.gitversion.outputs.SemVer}} files: |- cdl_downloader_${{steps.gitversion.outputs.SemVer}}.tar.gz cdl_downloader_${{steps.gitversion.outputs.SemVer}}.zip