Skip to content

Commit 28d0b4e

Browse files
committed
chore: codecov token is empty
1 parent 6b31429 commit 28d0b4e

File tree

2 files changed

+2
-12
lines changed

2 files changed

+2
-12
lines changed

.github/workflows/test.yml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -287,6 +287,4 @@ jobs:
287287
run: npm run test-merge-coverage:ci:affected
288288
- name: Report Coverage with Flags
289289
run: node ./scripts/codecov-upload-flags.mjs ${{ github.event.pull_request.head.label }} ${{ github.event.pull_request.head.sha }}
290-
env:
291-
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
292290

scripts/codecov-upload-flags.mjs

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@ import path from 'path';
55

66
const branchName = process.argv[2];
77
const commitSha = process.argv[3];
8-
const codecovToken = process.env.CODECOV_TOKEN;
98

109
if (typeof branchName !== 'string') {
1110
console.log('Branch name missing! Exiting');
@@ -15,10 +14,6 @@ if (typeof commitSha !== 'string') {
1514
console.log('Commit sha missing! Exiting');
1615
process.exit(-1);
1716
}
18-
if (typeof codecovToken !== 'string') {
19-
console.log('CODECOV_TOKEN env var missing! Exiting');
20-
process.exit(-1);
21-
}
2217

2318
const ROOT_DIR = process.cwd();
2419
const readPkg = (dir) => JSON.parse(readFileSync(path.join(dir, 'package.json'), 'utf8'));
@@ -41,7 +36,6 @@ const pkgsWithFlag = pkgFiles.flat().map((f) => {
4136
const command = [
4237
'./codecov --verbose',
4338
'upload-coverage',
44-
'--token <token>',
4539
'--git-service github',
4640
// we don't need xcrun or pycoverage plugins
4741
'--plugin gcov',
@@ -89,9 +83,7 @@ chmodSync(codecovPath, 0o555);
8983
// Compute the commands to run
9084
for (const pkg of pkgsWithFlag) {
9185
if (existsSync(pkg.report)) {
92-
const commandForLog = pkg.command;
93-
const commandForShell = pkg.command.replace('<token>', codecovToken);
94-
console.log(`\n\nCODECOV: Uploading report of "${pkg.name}" with flag "${pkg.flag}"\n${commandForLog}`);
95-
execCmd(commandForShell);
86+
console.log(`\n\nCODECOV: Uploading report of "${pkg.name}" with flag "${pkg.flag}"\n${pkg.command}`);
87+
execCmd(pkg.command);
9688
}
9789
}

0 commit comments

Comments
 (0)