mirror of
https://github.com/gradle/gradle-build-action.git
synced 2024-11-21 15:51:03 -05:00
Build outputs
This commit is contained in:
parent
87ccc98a2a
commit
5658338fb0
4 changed files with 46 additions and 12 deletions
27
dist/main/index.js
vendored
27
dist/main/index.js
vendored
|
@ -70667,7 +70667,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|||
return (mod && mod.__esModule) ? mod : { "default": mod };
|
||||
};
|
||||
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
||||
exports.constructJobCorrelator = exports.getJobCorrelator = exports.complete = exports.setup = void 0;
|
||||
exports.constructJobCorrelator = exports.complete = exports.setup = void 0;
|
||||
const core = __importStar(__nccwpck_require__(2186));
|
||||
const artifact = __importStar(__nccwpck_require__(2605));
|
||||
const github = __importStar(__nccwpck_require__(5438));
|
||||
|
@ -70683,10 +70683,12 @@ function setup(option) {
|
|||
return;
|
||||
}
|
||||
core.info('Enabling dependency graph generation');
|
||||
const jobCorrelator = getJobCorrelator();
|
||||
core.exportVariable('GITHUB_DEPENDENCY_GRAPH_ENABLED', 'true');
|
||||
core.exportVariable('GITHUB_JOB_CORRELATOR', jobCorrelator);
|
||||
core.exportVariable('GITHUB_JOB_ID', github.context.runId);
|
||||
core.exportVariable('GITHUB_DEPENDENCY_GRAPH_JOB_CORRELATOR', getJobCorrelator());
|
||||
core.exportVariable('GITHUB_DEPENDENCY_GRAPH_JOB_ID', github.context.runId);
|
||||
core.exportVariable('GITHUB_DEPENDENCY_GRAPH_REF', github.context.ref);
|
||||
core.exportVariable('GITHUB_DEPENDENCY_GRAPH_SHA', getShaFromContext());
|
||||
core.exportVariable('GITHUB_DEPENDENCY_GRAPH_WORKSPACE', layout.workspaceDirectory());
|
||||
core.exportVariable('DEPENDENCY_GRAPH_REPORT_DIR', path.resolve(layout.workspaceDirectory(), 'dependency-graph-reports'));
|
||||
}
|
||||
exports.setup = setup;
|
||||
|
@ -70800,10 +70802,25 @@ function getRelativePathFromWorkspace(file) {
|
|||
const workspaceDirectory = layout.workspaceDirectory();
|
||||
return path.relative(workspaceDirectory, file);
|
||||
}
|
||||
function getShaFromContext() {
|
||||
const context = github.context;
|
||||
const pullRequestEvents = [
|
||||
'pull_request',
|
||||
'pull_request_comment',
|
||||
'pull_request_review',
|
||||
'pull_request_review_comment'
|
||||
];
|
||||
if (pullRequestEvents.includes(context.eventName)) {
|
||||
const pr = context.payload.pull_request;
|
||||
return pr.head.sha;
|
||||
}
|
||||
else {
|
||||
return context.sha;
|
||||
}
|
||||
}
|
||||
function getJobCorrelator() {
|
||||
return constructJobCorrelator(github.context.workflow, github.context.job, (0, input_params_1.getJobMatrix)());
|
||||
}
|
||||
exports.getJobCorrelator = getJobCorrelator;
|
||||
function constructJobCorrelator(workflow, jobId, matrixJson) {
|
||||
const matrixString = describeMatrix(matrixJson);
|
||||
const label = matrixString ? `${workflow}-${jobId}-${matrixString}` : `${workflow}-${jobId}`;
|
||||
|
|
2
dist/main/index.js.map
vendored
2
dist/main/index.js.map
vendored
File diff suppressed because one or more lines are too long
27
dist/post/index.js
vendored
27
dist/post/index.js
vendored
|
@ -70667,7 +70667,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|||
return (mod && mod.__esModule) ? mod : { "default": mod };
|
||||
};
|
||||
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
||||
exports.constructJobCorrelator = exports.getJobCorrelator = exports.complete = exports.setup = void 0;
|
||||
exports.constructJobCorrelator = exports.complete = exports.setup = void 0;
|
||||
const core = __importStar(__nccwpck_require__(2186));
|
||||
const artifact = __importStar(__nccwpck_require__(2605));
|
||||
const github = __importStar(__nccwpck_require__(5438));
|
||||
|
@ -70683,10 +70683,12 @@ function setup(option) {
|
|||
return;
|
||||
}
|
||||
core.info('Enabling dependency graph generation');
|
||||
const jobCorrelator = getJobCorrelator();
|
||||
core.exportVariable('GITHUB_DEPENDENCY_GRAPH_ENABLED', 'true');
|
||||
core.exportVariable('GITHUB_JOB_CORRELATOR', jobCorrelator);
|
||||
core.exportVariable('GITHUB_JOB_ID', github.context.runId);
|
||||
core.exportVariable('GITHUB_DEPENDENCY_GRAPH_JOB_CORRELATOR', getJobCorrelator());
|
||||
core.exportVariable('GITHUB_DEPENDENCY_GRAPH_JOB_ID', github.context.runId);
|
||||
core.exportVariable('GITHUB_DEPENDENCY_GRAPH_REF', github.context.ref);
|
||||
core.exportVariable('GITHUB_DEPENDENCY_GRAPH_SHA', getShaFromContext());
|
||||
core.exportVariable('GITHUB_DEPENDENCY_GRAPH_WORKSPACE', layout.workspaceDirectory());
|
||||
core.exportVariable('DEPENDENCY_GRAPH_REPORT_DIR', path.resolve(layout.workspaceDirectory(), 'dependency-graph-reports'));
|
||||
}
|
||||
exports.setup = setup;
|
||||
|
@ -70800,10 +70802,25 @@ function getRelativePathFromWorkspace(file) {
|
|||
const workspaceDirectory = layout.workspaceDirectory();
|
||||
return path.relative(workspaceDirectory, file);
|
||||
}
|
||||
function getShaFromContext() {
|
||||
const context = github.context;
|
||||
const pullRequestEvents = [
|
||||
'pull_request',
|
||||
'pull_request_comment',
|
||||
'pull_request_review',
|
||||
'pull_request_review_comment'
|
||||
];
|
||||
if (pullRequestEvents.includes(context.eventName)) {
|
||||
const pr = context.payload.pull_request;
|
||||
return pr.head.sha;
|
||||
}
|
||||
else {
|
||||
return context.sha;
|
||||
}
|
||||
}
|
||||
function getJobCorrelator() {
|
||||
return constructJobCorrelator(github.context.workflow, github.context.job, (0, input_params_1.getJobMatrix)());
|
||||
}
|
||||
exports.getJobCorrelator = getJobCorrelator;
|
||||
function constructJobCorrelator(workflow, jobId, matrixJson) {
|
||||
const matrixString = describeMatrix(matrixJson);
|
||||
const label = matrixString ? `${workflow}-${jobId}-${matrixString}` : `${workflow}-${jobId}`;
|
||||
|
|
2
dist/post/index.js.map
vendored
2
dist/post/index.js.map
vendored
File diff suppressed because one or more lines are too long
Loading…
Reference in a new issue