mirror of
https://github.com/codecov/codecov-action.git
synced 2025-12-08 16:16:24 +00:00
Compare commits
11 Commits
v4.0.0-bet
...
v4-beta
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
428cda1b1c | ||
|
|
572779f95b | ||
|
|
d6353e1297 | ||
|
|
d6b8a01e05 | ||
|
|
59959656dc | ||
|
|
3f71d3b255 | ||
|
|
266a44bf8b | ||
|
|
2409ca5030 | ||
|
|
b65fbdcf97 | ||
|
|
c4cf8a4f03 | ||
|
|
845c445181 |
6
.github/workflows/codeql-analysis.yml
vendored
6
.github/workflows/codeql-analysis.yml
vendored
@@ -41,7 +41,7 @@ jobs:
|
||||
|
||||
# Initializes the CodeQL tools for scanning.
|
||||
- name: Initialize CodeQL
|
||||
uses: github/codeql-action/init@v2.21.5
|
||||
uses: github/codeql-action/init@v2.21.7
|
||||
with:
|
||||
languages: ${{ matrix.language }}
|
||||
# If you wish to specify custom queries, you can do so here or in a config file.
|
||||
@@ -52,7 +52,7 @@ jobs:
|
||||
# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
|
||||
# If this step fails, then you should remove it and run the build manually (see below)
|
||||
- name: Autobuild
|
||||
uses: github/codeql-action/autobuild@v2.21.5
|
||||
uses: github/codeql-action/autobuild@v2.21.7
|
||||
|
||||
# ℹ️ Command-line programs to run using the OS shell.
|
||||
# 📚 https://git.io/JvXDl
|
||||
@@ -66,4 +66,4 @@ jobs:
|
||||
# make release
|
||||
|
||||
- name: Perform CodeQL Analysis
|
||||
uses: github/codeql-action/analyze@v2.21.5
|
||||
uses: github/codeql-action/analyze@v2.21.7
|
||||
|
||||
2
.github/workflows/scorecards-analysis.yml
vendored
2
.github/workflows/scorecards-analysis.yml
vendored
@@ -56,6 +56,6 @@ jobs:
|
||||
|
||||
# Upload the results to GitHub's code scanning dashboard.
|
||||
- name: "Upload to code-scanning"
|
||||
uses: github/codeql-action/upload-sarif@v2.21.5 # v1.0.26
|
||||
uses: github/codeql-action/upload-sarif@v2.21.7 # v1.0.26
|
||||
with:
|
||||
sarif_file: results.sarif
|
||||
|
||||
@@ -1,3 +1,7 @@
|
||||
## 4.0.0-beta.2
|
||||
### Fixes
|
||||
- #1085 not adding -n if empty to do-upload command
|
||||
|
||||
## 4.0.0-beta.1
|
||||
|
||||
`v4` represents a move from the [universal uploader](https://github.com/codecov/uploader) to the [Codecov CLI](https://github.com/codecov/codecov-cli). Although this will unlock new features for our users, the CLI is not yet at feature parity with the universal uploader.
|
||||
|
||||
@@ -47,6 +47,9 @@ inputs:
|
||||
override_pr:
|
||||
description: 'Specify the pull request number'
|
||||
required: false
|
||||
plugins:
|
||||
description: 'Comma-separated list of plugins for use during upload.'
|
||||
required: false
|
||||
root_dir:
|
||||
description: 'Used when not in git/hg project to identify project root directory'
|
||||
required: false
|
||||
|
||||
18
dist/index.js
vendored
18
dist/index.js
vendored
File diff suppressed because one or more lines are too long
2
dist/index.js.map
vendored
2
dist/index.js.map
vendored
File diff suppressed because one or more lines are too long
1248
package-lock.json
generated
1248
package-lock.json
generated
File diff suppressed because it is too large
Load Diff
12
package.json
12
package.json
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "codecov-action",
|
||||
"version": "4.0.0-beta.1",
|
||||
"version": "4.0.0-beta.3",
|
||||
"description": "Upload coverage reports to Codecov from GitHub Actions",
|
||||
"main": "index.js",
|
||||
"scripts": {
|
||||
@@ -30,14 +30,14 @@
|
||||
"openpgp": "5.10"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@types/jest": "^29.5.4",
|
||||
"@types/node": "^20.6.0",
|
||||
"@typescript-eslint/eslint-plugin": "^6.7.0",
|
||||
"@typescript-eslint/parser": "^6.7.0",
|
||||
"@types/jest": "^29.5.5",
|
||||
"@types/node": "^20.6.3",
|
||||
"@typescript-eslint/eslint-plugin": "^6.7.2",
|
||||
"@typescript-eslint/parser": "^6.7.2",
|
||||
"@vercel/ncc": "^0.38.0",
|
||||
"eslint": "^8.49.0",
|
||||
"eslint-config-google": "^0.14.0",
|
||||
"jest": "^29.6.4",
|
||||
"jest": "^29.7.0",
|
||||
"jest-junit": "^16.0.0",
|
||||
"ts-jest": "^29.1.1",
|
||||
"typescript": "^5.2.0"
|
||||
|
||||
@@ -35,10 +35,7 @@ test('general args', () => {
|
||||
|
||||
|
||||
test('upload args using context', () => {
|
||||
const expectedArgs = [
|
||||
'-n',
|
||||
'',
|
||||
];
|
||||
const expectedArgs = [];
|
||||
const {uploadExecArgs, uploadCommand} = buildUploadExec();
|
||||
if (context.eventName == 'pull_request') {
|
||||
expectedArgs.push('-C', `${context.payload.pull_request.head.sha}`);
|
||||
@@ -65,6 +62,7 @@ test('upload args', () => {
|
||||
'override_build': '1',
|
||||
'override_commit': '9caabca5474b49de74ef5667deabaf74cdacc244',
|
||||
'override_pr': '2',
|
||||
'plugins': 'pycoverage,compress-pycoverage',
|
||||
'root_dir': 'root/',
|
||||
'slug': 'fakeOwner/fakeRepo',
|
||||
'token': 'd3859757-ab80-4664-924d-aef22fa7557b',
|
||||
@@ -102,6 +100,10 @@ test('upload args', () => {
|
||||
'9caabca5474b49de74ef5667deabaf74cdacc244',
|
||||
'-P',
|
||||
'2',
|
||||
'--plugin',
|
||||
'pycoverage',
|
||||
'--plugin',
|
||||
'compress-pycoverage',
|
||||
'--network-root-folder',
|
||||
'root/',
|
||||
'-s',
|
||||
|
||||
@@ -139,6 +139,7 @@ const buildUploadExec = () => {
|
||||
const overrideBuild = core.getInput('override_build');
|
||||
const overrideCommit = core.getInput('override_commit');
|
||||
const overridePr = core.getInput('override_pr');
|
||||
const plugins = core.getInput('plugins');
|
||||
const rootDir = core.getInput('root_dir');
|
||||
const searchDir = core.getInput('directory');
|
||||
const slug = core.getInput('slug');
|
||||
@@ -149,10 +150,6 @@ const buildUploadExec = () => {
|
||||
const exclude = core.getInput('exclude');
|
||||
|
||||
const uploadExecArgs = [];
|
||||
uploadExecArgs.push(
|
||||
'-n',
|
||||
`${name}`,
|
||||
);
|
||||
const uploadCommand = 'do-upload';
|
||||
const uploadOptions:any = {};
|
||||
uploadOptions.env = Object.assign(process.env, {
|
||||
@@ -172,7 +169,12 @@ const buildUploadExec = () => {
|
||||
envVarsArg.push(envVarClean);
|
||||
}
|
||||
}
|
||||
|
||||
if (name) {
|
||||
uploadExecArgs.push(
|
||||
'-n',
|
||||
`${name}`,
|
||||
);
|
||||
}
|
||||
if (token) {
|
||||
uploadOptions.env.CODECOV_TOKEN = token;
|
||||
}
|
||||
@@ -219,6 +221,11 @@ const buildUploadExec = () => {
|
||||
) {
|
||||
uploadExecArgs.push('-P', `${context.payload.number}`);
|
||||
}
|
||||
if (plugins) {
|
||||
plugins.split(',').map((p) => p.trim()).forEach((p) => {
|
||||
uploadExecArgs.push('--plugin', `${p}`);
|
||||
});
|
||||
}
|
||||
if (rootDir) {
|
||||
uploadExecArgs.push('--network-root-folder', `${rootDir}`);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user