diff --git a/.github/workflows/preview.yml b/.github/workflows/preview.yml index eca80e6..638915e 100644 --- a/.github/workflows/preview.yml +++ b/.github/workflows/preview.yml @@ -7,14 +7,14 @@ name: Build preview package jobs: deb-package: name: build DEB-Package - runs-on: ubuntu-20.04 + runs-on: ubuntu-24.04 concurrency: group: ${{ github.ref }} cancel-in-progress: true steps: - name: Checkout code - uses: actions/checkout@v2 + uses: actions/checkout@v3 - name: Install dependencies run: sudo apt update && sudo apt install debhelper build-essential -y @@ -26,7 +26,7 @@ jobs: run: mkdir package && cp ../linuxmuster-linuxclient7_* ./package - name: Upload artifact - uses: actions/upload-artifact@v2 + uses: actions/upload-artifact@v4 with: name: deb-package path: package/* diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 5894ab3..0bfb327 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -11,10 +11,10 @@ name: Build Release jobs: deb-package: name: build DEB-Package - runs-on: ubuntu-18.04 + runs-on: ubuntu-24.04 steps: - name: Checkout code - uses: actions/checkout@v2 + uses: actions/checkout@v3 - name: Install dependencies run: sudo apt update && sudo apt install debhelper build-essential -y @@ -26,7 +26,7 @@ jobs: run: mkdir package && cp ../linuxmuster-linuxclient7_* ./package - name: Upload artifact - uses: actions/upload-artifact@v2 + uses: actions/upload-artifact@v4 with: name: deb-package path: package/* @@ -35,17 +35,17 @@ jobs: needs: deb-package if: github.event_name == 'push' && contains(github.ref, 'refs/tags/') name: GitHub Release - runs-on: ubuntu-18.04 + runs-on: ubuntu-24.04 steps: - name: Download artifact - uses: actions/download-artifact@v2 + uses: actions/download-artifact@v4.1.7 with: name: deb-package - name: Extract current changes run: cat *.changes | sed '0,/^Changes:$/d' | sed '/Checksums.*/Q' | sed '1,2d' | tail >> ./current-changes - - name: Define distribution variable + - name: Define distribution variables run: | export DISTRIBUTION=$(grep -i ^Distribution *.changes | awk -F\: '{ print $2 }' | awk '{ print $1 }') echo "DISTRIBUTION=$DISTRIBUTION" >> $GITHUB_ENV @@ -53,24 +53,16 @@ jobs: export VERSION=$(grep -i ^Version *.changes | awk -F\: '{ print $2 }' | awk '{ print $1 }') echo "VERSION=$VERSION" >> $GITHUB_ENV - - name: Test if it's a testing prerelease - id: check_prerelease - uses: haya14busa/action-cond@v1 - with: - cond: ${{ env.DISTRIBUTION == 'lmn71' }} - if_true: "false" - if_false: "true" - - name: Create Release id: create_release - uses: actions/create-release@v1 + uses: softprops/action-gh-release@v1 env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} with: tag_name: ${{ github.ref }} release_name: Release ${{ env.VERSION }} (${{ env.DISTRIBUTION }}) draft: false - prerelease: ${{ steps.check_prerelease.outputs.value }} + prerelease: false body_path: ./current-changes - name: Delete current changes file @@ -85,7 +77,7 @@ jobs: release_id: ${{ steps.create_release.outputs.id }} assets_path: . - publsh: + publish: needs: deb-package name: Push latest release to archive repo if: github.event_name == 'push' && contains(github.ref, 'refs/tags/') && github.repository == 'linuxmuster/linuxmuster-linuxclient7' @@ -99,7 +91,7 @@ jobs: ssh-add - <<< "${{ secrets.REPO_SSH_KEY }}" - name: Clone archive repo - uses: actions/checkout@v2 + uses: actions/checkout@v3 with: repository: "linuxmuster/deb" ssh-key: ${{ secrets.REPO_SSH_KEY }} @@ -109,7 +101,7 @@ jobs: run: mkdir "package" - name: Download artifact - uses: actions/download-artifact@v2 + uses: actions/download-artifact@v4.1.7 with: name: deb-package path: "./package"