name: Create GitHub Release on: push: tags: - v* permissions: contents: write packages: write jobs: build: name: Test, Build, and Bundle runs-on: windows-latest steps: - name: Checkout uses: actions/checkout@v6 with: fetch-depth: 0 - name: Setup Node.js uses: actions/setup-node@v6 with: node-version: "lts/*" - name: Set up .NET uses: actions/setup-dotnet@v5 with: dotnet-version: '10' - name: Install Frontend Dependencies working-directory: client run: npm install - name: Build Frontend working-directory: client run: npm run build - name: Restore Backend Dependencies working-directory: server run: dotnet restore - name: Build and Publish Backend working-directory: server shell: pwsh run: | $v = "${{ github.ref_name }}".TrimStart('v') dotnet build -c Release --no-restore -p:Version=$v -p:AssemblyVersion=$v dotnet publish RdtClient.Web/RdtClient.Web.csproj -c Release --no-build -p:Version=$v -p:AssemblyVersion=$v -o ../publish - name: Create ZIP shell: pwsh run: Compress-Archive -Path publish\* -DestinationPath RealDebridClient.zip - name: Upload Artifact uses: actions/upload-artifact@v4 with: name: RealDebridClient.zip path: RealDebridClient.zip release: name: Create GitHub release runs-on: ubuntu-latest needs: build steps: - name: Checkout uses: actions/checkout@v6 with: fetch-depth: 0 - name: Strip 'v' from tag id: version run: echo "version=${GITHUB_REF_NAME#v}" >> $GITHUB_OUTPUT - name: Get latest release info id: query-release-info uses: release-flow/keep-a-changelog-action@v2 with: command: query version: ${{ steps.version.outputs.version }} - name: Download Artifact uses: actions/download-artifact@v4 with: name: RealDebridClient.zip - name: Create Release uses: softprops/action-gh-release@v2 with: tag_name: ${{ github.ref_name }} name: ${{ github.ref_name }} body: ${{ steps.query-release-info.outputs.release-notes }} draft: false prerelease: false files: RealDebridClient.zip token: ${{ secrets.GITHUB_TOKEN }}