Skip to content

Commit bf25e8e

Browse files
committed
Refactor CI for forked repositories - remove original uploads
1 parent 95650bd commit bf25e8e

File tree

8 files changed

+11
-76
lines changed

8 files changed

+11
-76
lines changed

.github/actions/reports-group/create-action/dist/index.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.github/actions/reports-group/create-action/dist/index.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.github/actions/reports-group/find-action/dist/index.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.github/actions/reports-group/find-action/dist/index.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.github/actions/reports-group/load-metadata-action/dist/index.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.github/actions/reports-group/load-metadata-action/dist/index.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,12 @@
11
const core = require('@actions/core'); // @TODO move to 'imports from' when moved to TS !
22

33
/**
4+
<<<<<<< HEAD
45
* @param {{[key: string]: string|number|boolean}} outputs
6+
=======
7+
* @param {Record<string, string|number|boolean>} outputs
8+
>>>>>>> 3640c55 (Refactor CI for forked repositories - remove original uploads)
59
*/
610
export function bindFrom(outputs) {
7-
Object.entries(outputs).map(([outputName, outputValue]) => {
8-
core.debug('Output ' + outputName + '=' +outputValue);
9-
core.setOutput(outputName, outputValue);
10-
});
11+
Object.entries(outputs).map(([outputName, outputValue]) => core.setOutput(outputName, outputValue));
1112
}

.github/workflows/CI.yml

Lines changed: 0 additions & 66 deletions
Original file line numberDiff line numberDiff line change
@@ -18,11 +18,8 @@ concurrency:
1818
env:
1919
TEST_OUTPUT_STYLE: pretty
2020
COMPOSER_OPTIONS: --optimize-autoloader
21-
CODACY_CACHE_PATH: ~/.cache/codacy
22-
CODACY_BIN: ~/.cache/codacy/codacy.sh
2321

2422
jobs:
25-
## Untrusted >>>
2623
debug-context:
2724
name: DEBUG - context
2825
runs-on: ubuntu-latest
@@ -234,66 +231,3 @@ jobs:
234231
235232
- name: Test
236233
run: make test-unit && make test-functional
237-
## <<< Untrusted
238-
## Trusted - to move to a workflow_run workflow >>>
239-
fetch-info:
240-
name: Fetch triggering workflow metadata
241-
runs-on: ubuntu-latest
242-
needs: [tests]
243-
permissions:
244-
contents: read
245-
checks: write # For the check run creation !
246-
outputs:
247-
commit-sha: ${{ steps.fetch-workflow-metadata.outputs.commit-sha }}
248-
run-id: ${{ steps.fetch-workflow-metadata.outputs.run-id }}
249-
steps:
250-
# @TODO move actions to a dedicated repo and remove the checkout
251-
- uses: actions/checkout@v4
252-
with:
253-
path: custom-action-repo
254-
255-
- uses: ./custom-action-repo/.github/actions/reports-group/attach-check-run-to-triggering-workflow-action
256-
with:
257-
github-token: ${{ github.token }}
258-
job-status: ${{ job.status }}
259-
fails-on-triggering-workflow-failure: true
260-
261-
- uses: ./custom-action-repo/.github/actions/reports-group/fetch-workflow-metadata-action
262-
id: fetch-workflow-metadata
263-
264-
codacy-uploader:
265-
name: Codacy
266-
needs: [fetch-info]
267-
uses: ./.github/workflows/codacy-upload-from-artifacts.yml
268-
with:
269-
artifacts-pattern: coverage-groups-*
270-
run-id: ${{ needs.fetch-info.outputs.run-id }}
271-
override-commit: ${{ needs.fetch-info.outputs.commit-sha }}
272-
permissions:
273-
contents: read
274-
checks: write # For the check run creation !
275-
secrets:
276-
PROJECT_TOKEN: ${{ secrets.CODACY_PROJECT_TOKEN }}
277-
278-
codecov-uploader:
279-
name: Codecov
280-
needs: [fetch-info]
281-
uses: ./.github/workflows/codecov-upload-from-artifacts.yml
282-
with:
283-
artifacts-pattern: coverage-groups-*
284-
run-id: ${{ needs.fetch-info.outputs.run-id }}
285-
override-commit: ${{ needs.fetch-info.outputs.commit-sha }}
286-
permissions:
287-
contents: read
288-
checks: write # For the check run creation !
289-
secrets:
290-
TOKEN: ${{ secrets.CODECOV_TOKEN }}
291-
292-
debug-uploads:
293-
name: DEBUG - Uploaders
294-
runs-on: ubuntu-latest
295-
needs: [ codacy-uploader, codecov-uploader ]
296-
steps:
297-
- run: echo 'codecov='"'"'${{ toJson(needs.codecov-uploader) }}'"'"
298-
- run: echo 'codacy='"'"'${{ toJson(needs.codacy-uploader) }}'"'"
299-
## <<< Trusted - to move to a workflow_run workflow

0 commit comments

Comments
 (0)