diff --git a/.github/workflows/lint-actions.yaml b/.github/workflows/actions-lint.yaml similarity index 100% rename from .github/workflows/lint-actions.yaml rename to .github/workflows/actions-lint.yaml diff --git a/.github/workflows/actions-up.yaml b/.github/workflows/actions-up.yaml new file mode 100644 index 0000000..38e3529 --- /dev/null +++ b/.github/workflows/actions-up.yaml @@ -0,0 +1,51 @@ +name: "Actions Up" + +on: + workflow_call: + inputs: + exclude: + type: string + default: "cssnr/.*,actions/.*" + +jobs: + actions-up: + name: "Actions Up" + runs-on: ubuntu-latest + timeout-minutes: 5 + + permissions: + pull-requests: write + + steps: + - name: "Debug CTX github" + continue-on-error: true + env: + GITHUB_CTX: ${{ toJSON(github) }} + run: echo "$GITHUB_CTX" + + - name: "Debug Checkout ref" + continue-on-error: true + run: | + echo "github.ref: ${{ github.ref }}" + echo "github.event.pull_request.head.sha: ${{ github.event.pull_request.head.sha }}" + echo "checkout ref: ${{ github.event.pull_request.head.sha || github.ref }}" + + - name: "Checkout" + uses: actions/checkout@v5 + with: + ref: ${{ github.event.pull_request.head.sha || github.ref }} + + - name: "Debug" + continue-on-error: true + run: | + echo "::group::ls" + ls -lAh . + echo "::endgroup::" + echo "::group::tree" + tree . + echo "::endgroup::" + + - name: "Actions Up" + uses: cssnr/actions-up-action@latest + with: + exclude: ${{ inputs.exclude }} diff --git a/.github/workflows/deploy-static.yaml b/.github/workflows/deploy-static.yaml index 9d71610..ec9b392 100644 --- a/.github/workflows/deploy-static.yaml +++ b/.github/workflows/deploy-static.yaml @@ -31,10 +31,6 @@ on: path: type: string -#concurrency: -# group: ${{ github.workflow }}-${{ github.ref }} -# cancel-in-progress: true - jobs: deploy: name: "Deploy" diff --git a/.github/workflows/labeler.yaml b/.github/workflows/labeler.yaml new file mode 100644 index 0000000..00f5f54 --- /dev/null +++ b/.github/workflows/labeler.yaml @@ -0,0 +1,48 @@ +name: "PR Labeler" + +on: + workflow_call: + +jobs: + labeler: + name: "Labeler" + runs-on: ubuntu-latest + timeout-minutes: 5 + + permissions: + issues: write + pull-requests: write + + steps: + - name: "Checkout Configs" + uses: actions/checkout@v5 + with: + repository: cssnr/configs + ref: master + path: .configs + sparse-checkout-cone-mode: false + sparse-checkout: | + labels/** + + - name: "Debug" + continue-on-error: true + run: | + echo "::group::labels.yaml" + cat .configs/labels/labels.yaml + echo "::endgroup::" + + echo "::group::labeler.yaml" + cat .configs/labels/labeler.yaml + echo "::endgroup::" + + - name: "Label Creator" + continue-on-error: true + uses: cssnr/label-creator-action@latest + with: + file: .configs/labels/labels.yaml + + - name: "Labeler" + uses: actions/labeler@v6 + with: + sync-labels: true + configuration-path: .configs/labels/labeler.yaml diff --git a/.github/workflows/npm-build.yaml b/.github/workflows/npm-build.yaml index 028e2a5..c4b9342 100644 --- a/.github/workflows/npm-build.yaml +++ b/.github/workflows/npm-build.yaml @@ -21,10 +21,6 @@ on: secrets: webhook: -#concurrency: -# group: ${{ github.workflow }}-${{ github.ref }} -# cancel-in-progress: true - jobs: build: name: "Build" diff --git a/.github/workflows/npm-outdated.yaml b/.github/workflows/npm-outdated.yaml new file mode 100644 index 0000000..16931af --- /dev/null +++ b/.github/workflows/npm-outdated.yaml @@ -0,0 +1,45 @@ +name: "NPM Outdated" + +on: + workflow_call: + +jobs: + npm-outdated: + name: "NPM Outdated" + runs-on: ubuntu-latest + timeout-minutes: 5 + + permissions: + pull-requests: write + + steps: + - name: "Debug CTX github" + continue-on-error: true + env: + GITHUB_CTX: ${{ toJSON(github) }} + run: echo "$GITHUB_CTX" + + - name: "Debug Checkout ref" + continue-on-error: true + run: | + echo "github.ref: ${{ github.ref }}" + echo "github.event.pull_request.head.sha: ${{ github.event.pull_request.head.sha }}" + echo "checkout ref: ${{ github.event.pull_request.head.sha || github.ref }}" + + - name: "Checkout" + uses: actions/checkout@v5 + with: + ref: ${{ github.event.pull_request.head.sha || github.ref }} + + - name: "Debug" + continue-on-error: true + run: | + echo "::group::ls" + ls -lAh . + echo "::endgroup::" + echo "::group::tree" + tree . + echo "::endgroup::" + + - name: "NPM Outdated Check" + uses: cssnr/npm-outdated-action@latest