From 72edae1f9bedcf5e66dcaa90465d9c4bca4a015e Mon Sep 17 00:00:00 2001 From: Ubax Date: Fri, 15 Mar 2024 12:13:28 +0100 Subject: [PATCH] chore: Adds create release on tag --- .github/workflows/matrix-test.yaml | 41 ---------------- .github/workflows/task-6.yaml | 78 +++++++++++++++++++++--------- 2 files changed, 55 insertions(+), 64 deletions(-) delete mode 100644 .github/workflows/matrix-test.yaml diff --git a/.github/workflows/matrix-test.yaml b/.github/workflows/matrix-test.yaml deleted file mode 100644 index 660c045..0000000 --- a/.github/workflows/matrix-test.yaml +++ /dev/null @@ -1,41 +0,0 @@ -name: matrix -run-name: Matrix workflow -on: - push - -jobs: - deploy-website: - strategy: - matrix: - os: [ubuntu-latest, windows-latest, macos-latest, macos-14] - runs-on: ${{ matrix.os }} - steps: - - name: Checkout code - uses: actions/checkout@v4 - - run: mkdir out - - run: echo "Hello, world! ${{ matrix.os }}" > out/hello.txt - - name: archive build - uses: actions/upload-artifact@v4 - with: - name: ${{ matrix.os }}-build - path: out - retention-days: 1 - - download-artifacts: - needs: deploy-website - runs-on: ubuntu-latest - steps: - - name: Checkout code - uses: actions/checkout@v4 - - name: Download builds - uses: actions/download-artifact@v4 - - name: List files - run: ls -Rl - # - name: Delete artifacts - # uses: actions/github-script@v7 - # script: | - # github.rest.actions.deleteArtifact({ - # issue_number: context.issue.number, - # owner: context.repo.owner, - # repo: context.repo.repo, - # }) diff --git a/.github/workflows/task-6.yaml b/.github/workflows/task-6.yaml index ca36184..1cf2f0b 100644 --- a/.github/workflows/task-6.yaml +++ b/.github/workflows/task-6.yaml @@ -1,35 +1,67 @@ name: task-6-workflow run-name: Task 6 workflow on: - push + push: + tags: + - desktop-app-** defaults: run: working-directory: desktop-app jobs: - deploy-website: - strategy: - matrix: - os: [ubuntu-latest, windows-latest, macos-latest, macos-14] - runs-on: ${{ matrix.os }} + # deploy-website: + # strategy: + # matrix: + # os: [ubuntu-latest, windows-latest, macos-latest, macos-14] + # runs-on: ${{ matrix.os }} + # outputs: + # build-artifact: ${{ steps.archive-build.outputs.artifact }} + # steps: + # - name: Checkout code + # uses: actions/checkout@v4 + # - name: Use Node.js LTS + # uses: actions/setup-node@v3 + # with: + # node-version: "lts/*" + # cache: "npm" + # cache-dependency-path: desktop-app + # - name: Install dependencies + # run: npm install + # - name: Build the app + # run: npm run make + # - name: List files + # run: ls + # - name: archive build + # uses: actions/upload-artifact@v4 + # with: + # name: ${{ matrix.os }}-build + # path: desktop-app/out + # retention-days: 1 + + # create-release: + # needs: deploy-website + # runs-on: ubuntu-latest + # steps: + # - name: Checkout code + # uses: actions/checkout@v4 + # - name: Download builds + # uses: actions/download-artifact@v4 + # with: + # path: release + # - name: List files + # run: ls -Rl + # - name: Create release + # uses: softprops/action-gh-release@v2 + # with: + # files: + + create-fast-release: + needs: deploy-website + runs-on: ubuntu-latest steps: - name: Checkout code uses: actions/checkout@v4 - - name: Use Node.js LTS - uses: actions/setup-node@v3 - with: - node-version: "lts/*" - cache: "npm" - cache-dependency-path: desktop-app - - name: Install dependencies - run: npm install - - name: Build the app - run: npm run make - - name: List files - run: ls - - name: archive build - uses: actions/upload-artifact@v2 + - name: Create release + uses: softprops/action-gh-release@v2 with: - name: ${{ matrix.os }}-build - path: desktop-app/out - retention-days: 1 + body: This is release