From 66186809c6b9f08a8c0985ef61199abc73f7b445 Mon Sep 17 00:00:00 2001 From: akondratov <22258361+andrey-kondratov@users.noreply.github.com> Date: Thu, 15 Aug 2024 01:00:13 +0300 Subject: [PATCH] Updated CI --- .github/workflows/build.yml | 23 +++++++++++++++++++++++ .github/workflows/{ci.yml => deploy.yml} | 21 ++------------------- 2 files changed, 25 insertions(+), 19 deletions(-) create mode 100644 .github/workflows/build.yml rename .github/workflows/{ci.yml => deploy.yml} (72%) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml new file mode 100644 index 0000000..4ce5801 --- /dev/null +++ b/.github/workflows/build.yml @@ -0,0 +1,23 @@ +name: Build + +on: + pull_request: + branches: + - master + push: + branches: + - master + +jobs: + build: + runs-on: ubuntu-latest + + steps: + - name: Checkout repo + uses: actions/checkout@v4 + - name: Restore tools + run: dotnet tool restore + - name: Build + run: dotnet cake + - name: Push + run: echo "${{ github.token }}" | dotnet cake --target Push --tag ${{ github.repository.is_default_branch && 'latest' || format('pr-{0}', github.event.pull_request.number) }} diff --git a/.github/workflows/ci.yml b/.github/workflows/deploy.yml similarity index 72% rename from .github/workflows/ci.yml rename to .github/workflows/deploy.yml index 6ccf436..811fa89 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/deploy.yml @@ -1,26 +1,9 @@ -name: CI +name: Deploy on: - pull_request: - branches: - - master - push: - branches: - - master + workflow_dispatch: jobs: - build: - runs-on: ubuntu-latest - - steps: - - name: Checkout repo - uses: actions/checkout@v4 - - name: Restore tools - run: dotnet tool restore - - name: Build - run: dotnet cake - - name: Push - run: echo "${{ github.token }}" | dotnet cake --target Push --tag ${{ github.repository.is_default_branch && 'latest' || format('pr-{0}', github.event.pull_request.number) }} deploy: runs-on: host,ARM64 environment: prod