diff --git a/src/config.ts b/src/config.ts index 85a91d4..fdc5d6a 100644 --- a/src/config.ts +++ b/src/config.ts @@ -7,6 +7,7 @@ export const Config = D.type({ INPUT_FILE_GLOB: D.string, INPUT_EVENT_NAME: D.string, INPUT_SPECTRAL_RULESET: D.string, + GITHUB_SERVER_URL: D.string, }); export type Config = D.TypeOf; diff --git a/src/index.ts b/src/index.ts index ba2829e..e0438e2 100644 --- a/src/index.ts +++ b/src/index.ts @@ -149,11 +149,11 @@ const program = pipe( annotations.findIndex(f => f.annotation_level === 'failure') === -1 ? 'success' : 'failure' ) ), - TE.map(({ checkResponse, repositoryInfo, annotations }) => { + TE.map(({ config, checkResponse, repositoryInfo, annotations }) => { checkResponse.map(res => { info(`Check run '${res.data.name}' concluded with '${res.data.conclusion}' (${res.data.html_url})`); info( - `Commit ${repositoryInfo.sha} has been annotated (https://github.com/${repositoryInfo.owner}/${repositoryInfo.repo}/commit/${repositoryInfo.sha})` + `Commit ${repositoryInfo.sha} has been annotated (${config.GITHUB_SERVER_URL}/${repositoryInfo.owner}/${repositoryInfo.repo}/commit/${repositoryInfo.sha})` ); });