@eve-horizon/cli 0.2.6 → 0.2.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/commands/job.js +32 -0
- package/package.json +1 -1
package/dist/commands/job.js
CHANGED
|
@@ -1012,6 +1012,22 @@ function formatJobDetails(job) {
|
|
|
1012
1012
|
console.log(` Key: ${job.workspace.key}`);
|
|
1013
1013
|
}
|
|
1014
1014
|
}
|
|
1015
|
+
// Resolved Git
|
|
1016
|
+
if (job.resolved_git) {
|
|
1017
|
+
const rg = job.resolved_git;
|
|
1018
|
+
console.log('');
|
|
1019
|
+
console.log(' Resolved Git:');
|
|
1020
|
+
if (rg.resolved_sha)
|
|
1021
|
+
console.log(` SHA: ${rg.resolved_sha}`);
|
|
1022
|
+
if (rg.resolved_branch)
|
|
1023
|
+
console.log(` Branch: ${rg.resolved_branch}`);
|
|
1024
|
+
if (rg.ref_source)
|
|
1025
|
+
console.log(` Source: ${rg.ref_source}`);
|
|
1026
|
+
if (rg.pushed !== undefined)
|
|
1027
|
+
console.log(` Pushed: ${rg.pushed}`);
|
|
1028
|
+
if (rg.commits?.length)
|
|
1029
|
+
console.log(` Commits: ${rg.commits.join(', ')}`);
|
|
1030
|
+
}
|
|
1015
1031
|
console.log('');
|
|
1016
1032
|
console.log(` Created: ${formatDate(job.created_at)}`);
|
|
1017
1033
|
console.log(` Updated: ${formatDate(job.updated_at)}`);
|
|
@@ -1795,6 +1811,22 @@ function formatResultFull(response) {
|
|
|
1795
1811
|
if (pipelineOutput?.deploy?.preview_url) {
|
|
1796
1812
|
console.log(`Preview: ${pipelineOutput.deploy.preview_url}`);
|
|
1797
1813
|
}
|
|
1814
|
+
// Display git metadata if present in result_json
|
|
1815
|
+
const resolvedGit = response.resultJson.resolved_git;
|
|
1816
|
+
if (resolvedGit) {
|
|
1817
|
+
console.log('');
|
|
1818
|
+
console.log('Git:');
|
|
1819
|
+
if (resolvedGit.resolved_sha)
|
|
1820
|
+
console.log(` SHA: ${resolvedGit.resolved_sha}`);
|
|
1821
|
+
if (resolvedGit.resolved_branch)
|
|
1822
|
+
console.log(` Branch: ${resolvedGit.resolved_branch}`);
|
|
1823
|
+
if (resolvedGit.ref_source)
|
|
1824
|
+
console.log(` Source: ${resolvedGit.ref_source}`);
|
|
1825
|
+
if (resolvedGit.pushed !== undefined)
|
|
1826
|
+
console.log(` Pushed: ${resolvedGit.pushed}`);
|
|
1827
|
+
if (resolvedGit.commits?.length)
|
|
1828
|
+
console.log(` Commits: ${resolvedGit.commits.join(', ')}`);
|
|
1829
|
+
}
|
|
1798
1830
|
}
|
|
1799
1831
|
console.log('');
|
|
1800
1832
|
console.log('Result:');
|