From 4c9974d9c2e6c2598ebe5e3d863027a991c4928a Mon Sep 17 00:00:00 2001 From: dd84ai Date: Mon, 30 Dec 2024 03:31:13 +0100 Subject: [PATCH] ci: switching to reused actions --- .github/workflows/autotag.yml | 17 ++++++----------- .github/workflows/build.yml | 15 ++++++--------- .github/workflows/ci.yml | 11 ++++------- .github/workflows/validate.yml | 7 ++++--- 4 files changed, 20 insertions(+), 30 deletions(-) diff --git a/.github/workflows/autotag.yml b/.github/workflows/autotag.yml index 715b346..2cf94c5 100644 --- a/.github/workflows/autotag.yml +++ b/.github/workflows/autotag.yml @@ -7,18 +7,13 @@ jobs: deploy: runs-on: ubuntu-22.04 steps: - - name: Install Task - run: | - sh -c "$(curl --location https://taskfile.dev/install.sh)" -- -d -b /usr/local/bin - + - name: Install Taskfile + uses: darklab8/infra/.github/actions/install-taskfile@master - name: Set up Go - uses: actions/setup-go@v5 - with: - go-version: '^1.22.5' + uses: darklab8/infra/.github/actions/install-go@master - - name: Install Autogit - run: | - curl -L $(curl -Ls -o /dev/null -w %{url_effective} https://github.com/darklab8/autogit/releases/latest | sed "s/releases\/tag/releases\/download/")/autogit-linux-amd64 -o /usr/local/bin/autogit && chmod 777 /usr/local/bin/autogit + - name: Install autogit + uses: darklab8/infra/.github/actions/install-autogit@master - name: Checkout repostiory with commit history! uses: actions/checkout@v3 @@ -37,4 +32,4 @@ jobs: repo: context.repo.repo, ref: "refs/tags/${{ steps.future_tag.outputs.version }}", sha: context.sha - }) \ No newline at end of file + }) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 27b87b3..e420b39 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -11,18 +11,15 @@ jobs: runs-on: ubuntu-22.04 steps: - - name: Install Task - run: | - sh -c "$(curl --location https://taskfile.dev/install.sh)" -- -d -b /usr/local/bin + - name: Install Taskfile + uses: darklab8/infra/.github/actions/install-taskfile@master - name: Set up Go - uses: actions/setup-go@v5 - with: - go-version: '^1.22.5' + uses: darklab8/infra/.github/actions/install-go@master + + - name: Install autogit + uses: darklab8/infra/.github/actions/install-autogit@master - - name: Install Autogit - run: | - curl -L $(curl -Ls -o /dev/null -w %{url_effective} https://github.com/darklab8/autogit/releases/latest | sed "s/releases\/tag/releases\/download/")/autogit-linux-amd64 -o /usr/local/bin/autogit && chmod 777 /usr/local/bin/autogit - name: Checkout git repo with tags and commits for autogit uses: actions/checkout@v3 with: diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 8206e0c..c4881d1 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -16,16 +16,13 @@ jobs: steps: - uses: actions/checkout@v3 - - name: Install Task - run: | - sh -c "$(curl --location https://taskfile.dev/install.sh)" -- -d -b /usr/local/bin + - name: Install Taskfile + uses: darklab8/infra/.github/actions/install-taskfile@master - name: Set up Go - uses: actions/setup-go@v5 - with: - go-version: '^1.22.5' + uses: darklab8/infra/.github/actions/install-go@master - - name: Setu pdeps + - name: Setup deps run: | echo 'ci version' > settings/version.txt diff --git a/.github/workflows/validate.yml b/.github/workflows/validate.yml index d4e8a9b..13f5bda 100644 --- a/.github/workflows/validate.yml +++ b/.github/workflows/validate.yml @@ -13,9 +13,10 @@ jobs: with: fetch-depth: 0 - - name: Install Autogit - run: | - curl -L $(curl -Ls -o /dev/null -w %{url_effective} https://github.com/darklab8/autogit/releases/latest | sed "s/releases\/tag/releases\/download/")/autogit-linux-amd64 -o /usr/local/bin/autogit && chmod 777 /usr/local/bin/autogit + - name: Set up Go + uses: darklab8/infra/.github/actions/install-go@master + - name: Install autogit + uses: darklab8/infra/.github/actions/install-autogit@master - name: Validate changelogs env: AUTOGIT_CONFIG_VALIDATION_RULES_HEADER_SUBJECT_MIN_WORDS: "2"