From c552aac73c7e9f744c11a0220af8450674ed151d Mon Sep 17 00:00:00 2001 From: Brendan F Date: Thu, 9 Jan 2025 00:50:12 -0500 Subject: Use proper naming and structure for a composite action --- .github/actions/build.yml | 21 --------------------- .github/actions/build/action.yml | 21 +++++++++++++++++++++ .github/workflows/build_website.yml | 2 +- .github/workflows/deploy_website.yml | 2 +- 4 files changed, 23 insertions(+), 23 deletions(-) delete mode 100644 .github/actions/build.yml create mode 100644 .github/actions/build/action.yml (limited to '.github') diff --git a/.github/actions/build.yml b/.github/actions/build.yml deleted file mode 100644 index fb2e198..0000000 --- a/.github/actions/build.yml +++ /dev/null @@ -1,21 +0,0 @@ -name: Build Website -runs: - using: "composite" - steps: - - name: Set Node.js - uses: actions/setup-node@v4 - with: - node-version: 20.x - cache: 'yarn' - - name: Set up Yarn2 - run: | - corepack enable - yarn set version berry - - name: Run install - uses: borales/actions-yarn@v5 - with: - cmd: install # will run `yarn install` command - - name: Build production bundle - uses: borales/actions-yarn@v5 - with: - cmd: build diff --git a/.github/actions/build/action.yml b/.github/actions/build/action.yml new file mode 100644 index 0000000..fb2e198 --- /dev/null +++ b/.github/actions/build/action.yml @@ -0,0 +1,21 @@ +name: Build Website +runs: + using: "composite" + steps: + - name: Set Node.js + uses: actions/setup-node@v4 + with: + node-version: 20.x + cache: 'yarn' + - name: Set up Yarn2 + run: | + corepack enable + yarn set version berry + - name: Run install + uses: borales/actions-yarn@v5 + with: + cmd: install # will run `yarn install` command + - name: Build production bundle + uses: borales/actions-yarn@v5 + with: + cmd: build diff --git a/.github/workflows/build_website.yml b/.github/workflows/build_website.yml index 5f765da..56a2200 100644 --- a/.github/workflows/build_website.yml +++ b/.github/workflows/build_website.yml @@ -10,4 +10,4 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 - - uses: ./.github/actions/build.yml + - uses: ./.github/actions/build diff --git a/.github/workflows/deploy_website.yml b/.github/workflows/deploy_website.yml index 19bce99..7c0557e 100644 --- a/.github/workflows/deploy_website.yml +++ b/.github/workflows/deploy_website.yml @@ -30,7 +30,7 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 - - uses: ./.github/actions/build.yml + - uses: ./.github/actions/build - name: Upload artifact uses: actions/upload-pages-artifact@v3 with: -- cgit v1.2.3