Commit c026f3a
Add server-url option for self-hosted GitHub instances (#234)
Implemented automatic server URL detection to support self-hosted GitHub
instances, matching the jest-coverage-comment implementation exactly.
- serverUrl is automatically calculated from context.serverUrl
- Falls back to 'https://github.com' for standard GitHub
- Updated repoUrl construction to use serverUrl for file links
- Added logging to show which GitHub URL is being used
This allows users running GitHub Enterprise Server or other self-hosted
GitHub instances to have coverage report links point to the correct server
automatically, without requiring any additional configuration.
Co-authored-by: Claude <noreply@anthropic.com>1 parent 10c84f1 commit c026f3a
2 files changed
Lines changed: 8 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
39505 | 39505 | | |
39506 | 39506 | | |
39507 | 39507 | | |
| 39508 | + | |
| 39509 | + | |
| 39510 | + | |
39508 | 39511 | | |
39509 | 39512 | | |
39510 | 39513 | | |
| |||
39536 | 39539 | | |
39537 | 39540 | | |
39538 | 39541 | | |
39539 | | - | |
| 39542 | + | |
39540 | 39543 | | |
39541 | 39544 | | |
39542 | 39545 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
198 | 198 | | |
199 | 199 | | |
200 | 200 | | |
| 201 | + | |
| 202 | + | |
| 203 | + | |
201 | 204 | | |
202 | 205 | | |
203 | 206 | | |
| |||
229 | 232 | | |
230 | 233 | | |
231 | 234 | | |
232 | | - | |
| 235 | + | |
233 | 236 | | |
234 | 237 | | |
235 | 238 | | |
| |||
0 commit comments