From ae44b6901aaa8f8095e7df51af7707480fdbea89 Mon Sep 17 00:00:00 2001 From: ivvist Date: Sun, 17 Nov 2024 22:52:21 +0100 Subject: [PATCH] add cache go mod files --- .github/workflows/ci_reuse_go_cas.yml | 21 ++++++++++----------- dist/index.js | 7 +------ index.js | 7 +------ 3 files changed, 12 insertions(+), 23 deletions(-) diff --git a/.github/workflows/ci_reuse_go_cas.yml b/.github/workflows/ci_reuse_go_cas.yml index 92f773f..83ee19c 100644 --- a/.github/workflows/ci_reuse_go_cas.yml +++ b/.github/workflows/ci_reuse_go_cas.yml @@ -40,12 +40,12 @@ jobs: - name: Checkout uses: actions/checkout@v4 -# - name: Check pull request file size -# if: github.event_name == 'pull_request' -# run: curl -s https://raw.githubusercontent.com/untillpro/ci-action/master/scripts/checkPR.sh | bash -# env: -# token: ${{ secrets.reporeading_token }} -# pr_number: ${{ github.event.number }} + - name: Check pull request file size + if: github.event_name == 'pull_request' + run: curl -s https://raw.githubusercontent.com/untillpro/ci-action/master/scripts/checkPR.sh | bash + env: + token: ${{ secrets.reporeading_token }} + pr_number: ${{ github.event.number }} - name: CI uses: untillpro/ci-action@master @@ -58,7 +58,6 @@ jobs: short-test: ${{ inputs.short_test }} ignore-build: ${{ inputs.ignore_build }} run-mod-tidy: false - stop-test: true env: CHARGEBEE_PUBLISHABLE_KEY: ${{ secrets.chargebee_token }} CHARGEBEE_SITE_NAME: ${{ secrets.chargebee_sitename }} @@ -86,8 +85,8 @@ jobs: path: | ~/.cache/go-build -# - name: Check copyright -# run: curl -s https://raw.githubusercontent.com/untillpro/ci-action/master/scripts/check_copyright.sh | bash -s "$(go env GOPATH)" + - name: Check copyright + run: curl -s https://raw.githubusercontent.com/untillpro/ci-action/master/scripts/check_copyright.sh | bash -s "$(go env GOPATH)" -# - name: Linters -# run: curl -s https://raw.githubusercontent.com/untillpro/ci-action/master/scripts/gbash.sh | bash -s "$(go env GOPATH)" + - name: Linters + run: curl -s https://raw.githubusercontent.com/untillpro/ci-action/master/scripts/gbash.sh | bash -s "$(go env GOPATH)" diff --git a/dist/index.js b/dist/index.js index cb12622..676833c 100644 --- a/dist/index.js +++ b/dist/index.js @@ -17347,7 +17347,6 @@ async function run() { const ignoreRunBuild = core.getInput('ignore-build') const testfolder = core.getInput('test-folder') const shorttest = core.getInput ('short-test') - const stoptest = core.getInput ('stop-test') const repositoryOwner = repository.split('/')[0] || github.context.payload && github.context.payload.repository && github.context.payload.repository.owner && github.context.payload.repository.owner.login @@ -17445,11 +17444,7 @@ async function run() { if (shorttest === "true"){ tststr=tststr + ' -short' } - if (!stoptest){ - await execute(tststr) - } else { - await execute('go mod tidy') - } + await execute(tststr) } if (testfolder.length != 0) { await execute('cd .') diff --git a/index.js b/index.js index fa504f8..cb77029 100644 --- a/index.js +++ b/index.js @@ -34,7 +34,6 @@ async function run() { const ignoreRunBuild = core.getInput('ignore-build') const testfolder = core.getInput('test-folder') const shorttest = core.getInput ('short-test') - const stoptest = core.getInput ('stop-test') const repositoryOwner = repository.split('/')[0] || github.context.payload && github.context.payload.repository && github.context.payload.repository.owner && github.context.payload.repository.owner.login @@ -132,11 +131,7 @@ async function run() { if (shorttest === "true"){ tststr=tststr + ' -short' } - if (!stoptest){ - await execute(tststr) - } else { - await execute('go mod tidy') - } + await execute(tststr) } if (testfolder.length != 0) { await execute('cd .')