Usenet streaming with a WebDAV server and a SABnzbd-compatible API
C#
chore(ci): release management via conventional commits (#306)
Anthony Hoivikcb06c2be3080
diff --git a/.github/dependabot.yml b/.github/dependabot.ymlnew file mode 100644index 00000000..2f693ef6--- /dev/null+++ b/.github/dependabot.yml@@ -0,0 +1,26 @@+version: 2++updates:+ - package-ecosystem: "github-actions"+ directory: "/"+ schedule:+ interval: "monthly"+ commit-message:+ prefix: "fix(deps)"+ open-pull-requests-limit: 15++ - package-ecosystem: "npm"+ directory: "/frontend"+ schedule:+ interval: "monthly"+ commit-message:+ prefix: "fix(deps)"+ open-pull-requests-limit: 15++ - package-ecosystem: "nuget"+ directory: "/backend"+ schedule:+ interval: "monthly"+ commit-message:+ prefix: "fix(deps)"+ open-pull-requests-limit: 15\ No newline at end of filediff --git a/.github/workflows/docker-publish.yml b/.github/workflows/docker-publish.ymldeleted file mode 100644index 63f82cee..00000000--- a/.github/workflows/docker-publish.yml+++ /dev/null@@ -1,83 +0,0 @@-name: Build and Push Docker image to GHCR--on:- push:- branches:- - '**'- workflow_dispatch:--jobs:- build-and-push:- runs-on: ubuntu-latest-- permissions:- contents: read- packages: write-- steps:- - name: Checkout repository- uses: actions/checkout@v4-- - name: Set up QEMU- uses: docker/setup-qemu-action@v3-- - name: Set up Docker Buildx- uses: docker/setup-buildx-action@v3-- - name: Log in to GHCR- uses: docker/login-action@v3- with:- registry: ghcr.io- username: ${{ github.actor }}- password: ${{ secrets.GITHUB_TOKEN }}-- - name: Log in to Docker Hub- uses: docker/login-action@v3- with:- registry: docker.io- username: ${{ secrets.DOCKERHUB_USERNAME }}- password: ${{ secrets.DOCKERHUB_TOKEN }}-- - name: Set tags and NZBDAV_VERSION- id: set_vars- run: |- MAJOR=0- MINOR=6- PATCH=$(( ${{ github.run_number }} - 154 ))-- if [[ "${{ github.ref_name }}" == "main" ]]; then- echo "NZBDAV_VERSION=${MAJOR}.${MINOR}.${PATCH}" >> $GITHUB_OUTPUT- else- echo "NZBDAV_VERSION=${{ github.ref_name }}" >> $GITHUB_OUTPUT- fi-- GHCR_REPO="ghcr.io/${{ github.repository }}"- DOCKERHUB_REPO="nzbdav/nzbdav"- if [[ "${{ github.ref_name }}" == "main" ]]; then- {- echo "TAGS<<EOF"- echo "${GHCR_REPO}:alpha"- echo "${GHCR_REPO}:latest"- echo "${GHCR_REPO}:${MAJOR}.x"- echo "${GHCR_REPO}:${MAJOR}.${MINOR}.x"- echo "${GHCR_REPO}:${MAJOR}.${MINOR}.${PATCH}"- echo "${DOCKERHUB_REPO}:alpha"- echo "${DOCKERHUB_REPO}:latest"- echo "${DOCKERHUB_REPO}:${MAJOR}.x"- echo "${DOCKERHUB_REPO}:${MAJOR}.${MINOR}.x"- echo "${DOCKERHUB_REPO}:${MAJOR}.${MINOR}.${PATCH}"- echo "EOF"- } >> $GITHUB_OUTPUT- else- echo "TAGS=${GHCR_REPO}:${{ github.ref_name }}" >> $GITHUB_OUTPUT- fi-- - name: Build and push Docker image (amd64 + arm64)- uses: docker/build-push-action@v5- with:- context: .- push: true- platforms: linux/amd64,linux/arm64- tags: ${{ steps.set_vars.outputs.TAGS }}- build-args: |- NZBDAV_VERSION=${{ steps.set_vars.outputs.NZBDAV_VERSION }}\ No newline at end of filediff --git a/.github/workflows/pre-release.yml b/.github/workflows/pre-release.ymlnew file mode 100644index 00000000..3d6e72e4--- /dev/null+++ b/.github/workflows/pre-release.yml@@ -0,0 +1,57 @@+name: "Deploy Pre-Release/Dev"++on:+ push:+ branches:+ - '**'+ - '!main'++ workflow_dispatch:++jobs:+ build-and-push:+ runs-on: ubuntu-latest++ permissions:+ contents: read+ packages: write++ steps:+ - name: Checkout repository+ uses: actions/checkout@v4++ - name: Set up QEMU+ uses: docker/setup-qemu-action@v3++ - name: Set up Docker Buildx+ uses: docker/setup-buildx-action@v3++ - name: Log in to GHCR+ uses: docker/login-action@v3+ with:+ registry: ghcr.io+ username: ${{ github.actor }}+ password: ${{ secrets.GITHUB_TOKEN }}++ - name: Set tags and NZBDAV_VERSION+ id: set_vars+ run: |+ RAW_REF="${{ github.ref_name }}"+ DOCKER_TAG=$(echo "$RAW_REF" \+ | tr '[:upper:]' '[:lower:]' \+ | sed -E 's#[^a-z0-9._-]+#-#g' \+ | sed -E 's#(^-+|-+$)##g')+ echo "DOCKER_TAG: $DOCKER_TAG"+ echo "NZBDAV_VERSION=${{ github.ref_name }}" >> $GITHUB_OUTPUT+ GHCR_REPO="ghcr.io/${{ github.repository }}"+ echo "TAGS=${GHCR_REPO}:${DOCKER_TAG}" >> $GITHUB_OUTPUT++ - name: Build and push Docker image (amd64 + arm64)+ uses: docker/build-push-action@v5+ with:+ context: .+ push: true+ platforms: linux/amd64,linux/arm64+ tags: ${{ steps.set_vars.outputs.TAGS }}+ build-args: |+ NZBDAV_VERSION=${{ steps.set_vars.outputs.NZBDAV_VERSION }}\ No newline at end of filediff --git a/.github/workflows/release.yml b/.github/workflows/release.ymlnew file mode 100644index 00000000..e56d4865--- /dev/null+++ b/.github/workflows/release.yml@@ -0,0 +1,112 @@+name: "Deploy Versioned Release"++on:+ push:+ branches:+ - main+ paths-ignore:+ - ".github/**"++jobs:+ release:+ runs-on: ubuntu-latest+ outputs:+ release_created: ${{ steps.release.outputs.release_created }}+ major: ${{ steps.release.outputs.major }}+ minor: ${{ steps.release.outputs.minor }}+ patch: ${{ steps.release.outputs.patch }}+ permissions:+ contents: write+ pull-requests: write+ steps:+ - uses: googleapis/release-please-action@v4+ id: release+ with:+ config-file: .release-please-config.json+ - uses: actions/checkout@v6+ - name: tag major and minor versions+ if: ${{ steps.release.outputs.release_created }}+ run: |+ git config user.name "GitHub Actions"+ git config user.email "<>"+ git tag -d latest || true+ git tag -d v${{ steps.release.outputs.major }}.x || true+ git tag -d v${{ steps.release.outputs.major }}.${{ steps.release.outputs.minor }}.x || true+ git push origin :latest || true+ git push origin :v${{ steps.release.outputs.major }}.x || true+ git push origin :v${{ steps.release.outputs.major }}.${{ steps.release.outputs.minor }}.x || true+ git tag -a latest -m "Release latest"+ git tag -a v${{ steps.release.outputs.major }}.x -m "Release v${{ steps.release.outputs.major }}.x"+ git tag -a v${{ steps.release.outputs.major }}.${{ steps.release.outputs.minor }}.x -m "Release v${{ steps.release.outputs.major }}.${{ steps.release.outputs.minor }}.x"+ git push origin latest+ git push origin v${{ steps.release.outputs.major }}.x+ git push origin v${{ steps.release.outputs.major }}.${{ steps.release.outputs.minor }}.x++ deploy:+ if: ${{ needs.release.outputs.release_created }}+ needs: release+ runs-on: ubuntu-latest++ permissions:+ contents: read+ packages: write++ steps:+ - name: Checkout repository+ uses: actions/checkout@v4++ - name: Set up QEMU+ uses: docker/setup-qemu-action@v3++ - name: Set up Docker Buildx+ uses: docker/setup-buildx-action@v3++ - name: Log in to GHCR+ uses: docker/login-action@v3+ with:+ registry: ghcr.io+ username: ${{ github.actor }}+ password: ${{ secrets.GITHUB_TOKEN }}++ - name: Log in to Docker Hub+ uses: docker/login-action@v3+ with:+ registry: docker.io+ username: ${{ secrets.DOCKERHUB_USERNAME }}+ password: ${{ secrets.DOCKERHUB_TOKEN }}++ - name: Set tags and NZBDAV_VERSION+ id: set_vars+ run: |+ MAJOR=${{ needs.release.outputs.major }}+ MINOR=${{ needs.release.outputs.minor }}+ PATCH=${{ needs.release.outputs.patch }}++ echo "NZBDAV_VERSION=${MAJOR}.${MINOR}.${PATCH}" >> $GITHUB_OUTPUT++ GHCR_REPO="ghcr.io/${{ github.repository }}"+ DOCKERHUB_REPO="nzbdav/nzbdav"+ {+ echo "TAGS<<EOF"+ echo "${GHCR_REPO}:alpha"+ echo "${GHCR_REPO}:latest"+ echo "${GHCR_REPO}:${MAJOR}.x"+ echo "${GHCR_REPO}:${MAJOR}.${MINOR}.x"+ echo "${GHCR_REPO}:${MAJOR}.${MINOR}.${PATCH}"+ echo "${DOCKERHUB_REPO}:alpha"+ echo "${DOCKERHUB_REPO}:latest"+ echo "${DOCKERHUB_REPO}:${MAJOR}.x"+ echo "${DOCKERHUB_REPO}:${MAJOR}.${MINOR}.x"+ echo "${DOCKERHUB_REPO}:${MAJOR}.${MINOR}.${PATCH}"+ echo "EOF"+ } >> $GITHUB_OUTPUT++ - name: Build and push Docker image (amd64 + arm64)+ uses: docker/build-push-action@v5+ with:+ context: .+ push: true+ platforms: linux/amd64,linux/arm64+ tags: ${{ steps.set_vars.outputs.TAGS }}+ build-args: |+ NZBDAV_VERSION=${{ steps.set_vars.outputs.NZBDAV_VERSION }}\ No newline at end of filediff --git a/.release-please-config.json b/.release-please-config.jsonnew file mode 100644index 00000000..415ae234--- /dev/null+++ b/.release-please-config.json@@ -0,0 +1,9 @@+{+ "packages": {+ ".": {+ "release-type": "simple",+ "bump-minor-pre-major": true,+ "bump-patch-for-minor-pre-major": true+ }+ }+}diff --git a/.release-please-manifest.json b/.release-please-manifest.jsonnew file mode 100644index 00000000..4208b5cb--- /dev/null+++ b/.release-please-manifest.json@@ -0,0 +1,3 @@+{+ ".": "0.6.0"+}\ No newline at end of filediff --git a/version.txt b/version.txtnew file mode 100644index 00000000..09a3acfa--- /dev/null+++ b/version.txt@@ -0,0 +1 @@+0.6.0\ No newline at end of file