Compare commits

..

11 Commits

Author SHA1 Message Date
Tom Hu
428cda1b1c feat: add plugins (#1099)
* feat: add plugins

* fix: add test
2023-09-22 17:29:50 -05:00
dependabot[bot]
572779f95b build(deps-dev): bump @typescript-eslint/parser from 6.7.0 to 6.7.2 (#1097)
Bumps [@typescript-eslint/parser](https://github.com/typescript-eslint/typescript-eslint/tree/HEAD/packages/parser) from 6.7.0 to 6.7.2.
- [Release notes](https://github.com/typescript-eslint/typescript-eslint/releases)
- [Changelog](https://github.com/typescript-eslint/typescript-eslint/blob/main/packages/parser/CHANGELOG.md)
- [Commits](https://github.com/typescript-eslint/typescript-eslint/commits/v6.7.2/packages/parser)

---
updated-dependencies:
- dependency-name: "@typescript-eslint/parser"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-09-21 12:26:09 -05:00
dependabot[bot]
d6353e1297 build(deps-dev): bump @types/node from 20.6.2 to 20.6.3 (#1098)
Bumps [@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node) from 20.6.2 to 20.6.3.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node)

---
updated-dependencies:
- dependency-name: "@types/node"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-09-21 12:22:43 -05:00
dependabot[bot]
d6b8a01e05 build(deps-dev): bump @typescript-eslint/eslint-plugin from 6.7.0 to 6.7.2 (#1095)
build(deps-dev): bump @typescript-eslint/eslint-plugin

Bumps [@typescript-eslint/eslint-plugin](https://github.com/typescript-eslint/typescript-eslint/tree/HEAD/packages/eslint-plugin) from 6.7.0 to 6.7.2.
- [Release notes](https://github.com/typescript-eslint/typescript-eslint/releases)
- [Changelog](https://github.com/typescript-eslint/typescript-eslint/blob/main/packages/eslint-plugin/CHANGELOG.md)
- [Commits](https://github.com/typescript-eslint/typescript-eslint/commits/v6.7.2/packages/eslint-plugin)

---
updated-dependencies:
- dependency-name: "@typescript-eslint/eslint-plugin"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-09-21 12:15:35 -05:00
dependabot[bot]
59959656dc build(deps): bump openpgp from 5.10.1 to 5.10.2 (#1096)
Bumps [openpgp](https://github.com/openpgpjs/openpgpjs) from 5.10.1 to 5.10.2.
- [Release notes](https://github.com/openpgpjs/openpgpjs/releases)
- [Commits](https://github.com/openpgpjs/openpgpjs/compare/v5.10.1...v5.10.2)

---
updated-dependencies:
- dependency-name: openpgp
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-09-21 12:15:21 -05:00
dependabot[bot]
3f71d3b255 build(deps-dev): bump @types/node from 20.6.0 to 20.6.2 (#1093)
Bumps [@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node) from 20.6.0 to 20.6.2.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node)

---
updated-dependencies:
- dependency-name: "@types/node"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-09-18 11:41:05 -07:00
dependabot[bot]
266a44bf8b build(deps): bump github/codeql-action from 2.21.5 to 2.21.7 (#1094)
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 2.21.5 to 2.21.7.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](https://github.com/github/codeql-action/compare/v2.21.5...v2.21.7)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-09-18 11:10:01 -07:00
dependabot[bot]
2409ca5030 build(deps-dev): bump @types/jest from 29.5.4 to 29.5.5 (#1092)
Bumps [@types/jest](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/jest) from 29.5.4 to 29.5.5.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/jest)

---
updated-dependencies:
- dependency-name: "@types/jest"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-09-18 11:09:37 -07:00
dependabot[bot]
b65fbdcf97 build(deps-dev): bump jest from 29.6.4 to 29.7.0 (#1082)
Bumps [jest](https://github.com/jestjs/jest/tree/HEAD/packages/jest) from 29.6.4 to 29.7.0.
- [Release notes](https://github.com/jestjs/jest/releases)
- [Changelog](https://github.com/jestjs/jest/blob/main/CHANGELOG.md)
- [Commits](https://github.com/jestjs/jest/commits/v29.7.0/packages/jest)

---
updated-dependencies:
- dependency-name: jest
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-09-13 17:43:32 -07:00
Tom Hu
c4cf8a4f03 4.0.0-beta.2 (#1086) 2023-09-13 09:29:07 -07:00
Dana Yaish
845c445181 not adding -n if empty to do-upload command (#1085) 2023-09-13 19:20:12 +03:00
10 changed files with 690 additions and 632 deletions

View File

@@ -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

View File

@@ -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

View File

@@ -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.

View File

@@ -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

File diff suppressed because one or more lines are too long

2
dist/index.js.map vendored

File diff suppressed because one or more lines are too long

1248
package-lock.json generated

File diff suppressed because it is too large Load Diff

View File

@@ -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"

View File

@@ -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',

View File

@@ -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}`);
}