Skip to content

Commit d6f25c0

Browse files
Copilotneilime
andcommitted
Fix linting issues (formatting)
Co-authored-by: neilime <[email protected]>
1 parent 402d3df commit d6f25c0

File tree

6 files changed

+67
-67
lines changed

6 files changed

+67
-67
lines changed

.github/workflows/continuous-integration.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -56,11 +56,11 @@ on:
5656
Whether to enable linting.
5757
Set to `null` or empty to disable.
5858
Accepts a JSON object for lint options. See [lint action](../actions/lint/README.md).
59-
59+
6060
Supported options:
6161
- `command`: NPM script to run (default: "lint:ci"). The command should generate lint report files.
6262
- `report-file`: Path to lint report file for annotations.
63-
63+
6464
Example:
6565
```json
6666
{
@@ -86,12 +86,12 @@ on:
8686
Whether to enable testing.
8787
Set to `null` or empty to disable.
8888
Accepts a JSON object for test options. See [test action](../actions/test/README.md).
89-
89+
9090
Supported options:
9191
- `command`: NPM script to run (default: "test:ci"). The command should generate coverage report files.
9292
- `coverage`: Coverage reporter ("github", "codecov", or "" for none).
9393
- `coverage-files`: Path to coverage files for reporting.
94-
94+
9595
Example:
9696
```json
9797
{

actions/lint/README.md

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -62,19 +62,19 @@ Action to lint Node.js projects with support for pull request reporting and anno
6262
6363
## Inputs
6464
65-
| **Input** | **Description** | **Required** | **Default** |
66-
| ----------------------- | ---------------------------------------------------------------- | ------------ | ----------- |
67-
| **`working-directory`** | Working directory where lint commands are executed. | **false** | `.` |
68-
| | Can be absolute or relative to the repository root. | | |
69-
| **`container`** | Whether running in container mode (skips checkout and node setup)| **false** | `false` |
70-
| **`command`** | NPM/package manager script command to run for linting. | **false** | `lint:ci` |
71-
| | This should be a script defined in your package.json. | | |
72-
| | The command should generate lint report files in a standard format.| | |
73-
| **`report-file`** | Path to lint report file to process as GitHub annotations. | **false** | - |
74-
| | Supports ESLint JSON and Checkstyle XML formats. | | |
75-
| | If not specified, auto-detection will be attempted for common paths:| | |
76-
| | - eslint-report.json, eslint.json | | |
77-
| | - checkstyle-result.xml, checkstyle.xml | | |
65+
| **Input** | **Description** | **Required** | **Default** |
66+
| ----------------------- | -------------------------------------------------------------------- | ------------ | ----------- |
67+
| **`working-directory`** | Working directory where lint commands are executed. | **false** | `.` |
68+
| | Can be absolute or relative to the repository root. | | |
69+
| **`container`** | Whether running in container mode (skips checkout and node setup) | **false** | `false` |
70+
| **`command`** | NPM/package manager script command to run for linting. | **false** | `lint:ci` |
71+
| | This should be a script defined in your package.json. | | |
72+
| | The command should generate lint report files in a standard format. | | |
73+
| **`report-file`** | Path to lint report file to process as GitHub annotations. | **false** | - |
74+
| | Supports ESLint JSON and Checkstyle XML formats. | | |
75+
| | If not specified, auto-detection will be attempted for common paths: | | |
76+
| | - eslint-report.json, eslint.json | | |
77+
| | - checkstyle-result.xml, checkstyle.xml | | |
7878

7979
<!-- inputs:end -->
8080
<!-- secrets:start -->

actions/rewrite-report-paths/README.md

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -68,17 +68,17 @@ When running tests or linting in Docker containers, the file paths in generated
6868
6969
## Inputs
7070
71-
| **Input** | **Description** | **Required** | **Default** |
72-
| ----------------------- | ---------------------------------------------------------------- | ------------ | ----------- |
73-
| **`report-files`** | Path or glob pattern for report files to process. | **true** | - |
74-
| | Supports multiple files separated by newlines. | | |
71+
| **Input** | **Description** | **Required** | **Default** |
72+
| ----------------------- | ----------------------------------------------------------------------- | ------------ | ----------- |
73+
| **`report-files`** | Path or glob pattern for report files to process. | **true** | - |
74+
| | Supports multiple files separated by newlines. | | |
7575
| | Common patterns: coverage/\*\*, reports/\*\*, \*\*/\*.xml, \*\*/\*.json | | |
76-
| **`source-root`** | Source root path in the container that should be replaced. | **false** | - |
77-
| | If not specified, will attempt to auto-detect from file paths. | | |
78-
| **`target-root`** | Target root path in the repository. | **false** | - |
79-
| | Typically this is the GITHUB_WORKSPACE or a subdirectory. | | |
80-
| **`working-directory`** | Working directory where report files are located. | **false** | `.` |
81-
| | Can be absolute or relative to the repository root. | | |
76+
| **`source-root`** | Source root path in the container that should be replaced. | **false** | - |
77+
| | If not specified, will attempt to auto-detect from file paths. | | |
78+
| **`target-root`** | Target root path in the repository. | **false** | - |
79+
| | Typically this is the GITHUB_WORKSPACE or a subdirectory. | | |
80+
| **`working-directory`** | Working directory where report files are located. | **false** | `.` |
81+
| | Can be absolute or relative to the repository root. | | |
8282

8383
<!-- inputs:end -->
8484
<!-- secrets:start -->
@@ -87,10 +87,10 @@ When running tests or linting in Docker containers, the file paths in generated
8787

8888
## Outputs
8989

90-
| **Output** | **Description** |
91-
| --------------------- | ------------------------------------------------- |
92-
| **`files-processed`** | Number of report files that were processed |
93-
| **`paths-replaced`** | Total number of paths that were rewritten |
90+
| **Output** | **Description** |
91+
| --------------------- | ------------------------------------------ |
92+
| **`files-processed`** | Number of report files that were processed |
93+
| **`paths-replaced`** | Total number of paths that were rewritten |
9494

9595
<!-- outputs:end -->
9696
<!-- examples:start -->

actions/rewrite-report-paths/action.yml

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -46,43 +46,43 @@ runs:
4646
const fs = require('fs');
4747
const path = require('path');
4848
const { glob } = require('glob');
49-
49+
5050
const workingDirectory = process.env.WORKING_DIRECTORY || '.';
5151
const workDir = path.resolve(process.env.GITHUB_WORKSPACE, workingDirectory);
5252
const reportFilesInput = process.env.REPORT_FILES.trim();
53-
53+
5454
if (!reportFilesInput) {
5555
core.warning('No report files specified for path rewriting');
5656
return;
5757
}
58-
58+
5959
// Parse report files (can be newline separated or comma separated)
6060
const reportPatterns = reportFilesInput
6161
.split(/[\n,]/)
6262
.map(p => p.trim())
6363
.filter(Boolean);
64-
64+
6565
core.info(`Looking for report files matching patterns: ${reportPatterns.join(', ')}`);
66-
66+
6767
// Find all matching files
6868
let reportFiles = [];
6969
for (const pattern of reportPatterns) {
7070
const fullPattern = path.isAbsolute(pattern) ? pattern : path.join(workDir, pattern);
7171
const matches = await glob(fullPattern, { nodir: true });
7272
reportFiles.push(...matches);
7373
}
74-
74+
7575
if (reportFiles.length === 0) {
7676
core.warning(`No report files found matching patterns: ${reportPatterns.join(', ')}`);
7777
return;
7878
}
79-
79+
8080
core.info(`Found ${reportFiles.length} report file(s) to process`);
81-
81+
8282
// Determine source and target roots
8383
let sourceRoot = process.env.SOURCE_ROOT.trim();
8484
const targetRoot = process.env.TARGET_ROOT.trim() || process.env.GITHUB_WORKSPACE;
85-
85+
8686
// Auto-detect source root if not provided
8787
if (!sourceRoot) {
8888
// Common container working directories
@@ -107,12 +107,12 @@ runs:
107107
return;
108108
}
109109
}
110-
110+
111111
core.info(`Rewriting paths from "${sourceRoot}" to "${targetRoot}"`);
112-
112+
113113
let filesProcessed = 0;
114114
let pathsReplaced = 0;
115-
115+
116116
// Process each report file
117117
for (const reportFile of reportFiles) {
118118
try {
@@ -145,7 +145,7 @@ runs:
145145
core.warning(`Failed to process ${reportFile}: ${error.message}`);
146146
}
147147
}
148-
148+
149149
core.info(`\n📊 Summary: ${filesProcessed} file(s) processed, ${pathsReplaced} path(s) rewritten`);
150150
core.setOutput('files-processed', filesProcessed);
151151
core.setOutput('paths-replaced', pathsReplaced);

actions/test/README.md

Lines changed: 21 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -76,27 +76,27 @@ Action to test Node.js projects with support for coverage reporting and pull req
7676
7777
## Inputs
7878
79-
| **Input** | **Description** | **Required** | **Default** |
80-
| ----------------------- | --------------------------------------------------------------------- | ------------ | ----------- |
81-
| **`working-directory`** | Working directory where test commands are executed. | **false** | `.` |
82-
| | Can be absolute or relative to the repository root. | | |
83-
| **`container`** | Whether running in container mode (skips checkout and node setup) | **false** | `false` |
84-
| **`command`** | NPM/package manager script command to run for testing. | **false** | `test:ci` |
85-
| | This should be a script defined in your package.json. | | |
86-
| | The command should generate coverage report files in a standard format.| | |
87-
| **`coverage`** | Code coverage reporter to use. Supported values: | **false** | `github` |
88-
| | - "github": Use ReportGenerator for PR comments with coverage reports | | |
89-
| | - "codecov": Upload coverage to Codecov | | |
90-
| | - "": No coverage reporting | | |
91-
| **`coverage-files`** | Path to coverage files for reporting. | **false** | - |
92-
| | Supports multiple formats (Cobertura, OpenCover, lcov, etc.). | | |
93-
| | Can be a single file or multiple files separated by semicolons. | | |
94-
| | If not specified, auto-detection will be attempted for common paths: | | |
95-
| | - coverage/cobertura-coverage.xml, coverage/coverage.xml | | |
96-
| | - coverage/lcov.info | | |
97-
| | - coverage/clover.xml | | |
98-
| **`github-token`** | GitHub token for coverage PR comments. | **false** | - |
99-
| | Required when coverage is set to "github". | | |
79+
| **Input** | **Description** | **Required** | **Default** |
80+
| ----------------------- | ----------------------------------------------------------------------- | ------------ | ----------- |
81+
| **`working-directory`** | Working directory where test commands are executed. | **false** | `.` |
82+
| | Can be absolute or relative to the repository root. | | |
83+
| **`container`** | Whether running in container mode (skips checkout and node setup) | **false** | `false` |
84+
| **`command`** | NPM/package manager script command to run for testing. | **false** | `test:ci` |
85+
| | This should be a script defined in your package.json. | | |
86+
| | The command should generate coverage report files in a standard format. | | |
87+
| **`coverage`** | Code coverage reporter to use. Supported values: | **false** | `github` |
88+
| | - "GitHub": Use ReportGenerator for PR comments with coverage reports | | |
89+
| | - "Codecov": Upload coverage to Codecov | | |
90+
| | - "": No coverage reporting | | |
91+
| **`coverage-files`** | Path to coverage files for reporting. | **false** | - |
92+
| | Supports multiple formats (Cobertura, OpenCover, lcov, etc.). | | |
93+
| | Can be a single file or multiple files separated by semicolons. | | |
94+
| | If not specified, auto-detection will be attempted for common paths: | | |
95+
| | - coverage/cobertura-coverage.xml, coverage/coverage.xml | | |
96+
| | - coverage/lcov.info | | |
97+
| | - coverage/clover.xml | | |
98+
| **`github-token`** | GitHub token for coverage PR comments. | **false** | - |
99+
| | Required when coverage is set to "GitHub". | | |
100100

101101
<!-- inputs:end -->
102102
<!-- secrets:start -->

actions/test/action.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -83,9 +83,9 @@ runs:
8383
const workingDirectory = process.env.WORKING_DIRECTORY || '.';
8484
const runScriptCommand = process.env.RUN_TEST_COMMAND;
8585
const testCommand = process.env.TEST_COMMAND || 'test:ci';
86-
86+
8787
core.info(`🧪 Running test command: ${testCommand}...`);
88-
88+
8989
try {
9090
const result = await exec.getExecOutput(runScriptCommand, [testCommand], {
9191
cwd: require('path').resolve(process.env.GITHUB_WORKSPACE, workingDirectory),

0 commit comments

Comments
 (0)