Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions lib/interface/cli/helpers/validation.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ function _getPipelineName(filename) {
}

async function validatePipelineSpec(data) {
const specTemplate = _.get(data, 'spec.specTemplate');
const steps = _.get(data, 'spec.steps');
const stages = _.get(data, 'spec.stages');
const yamlObj = {};
Expand All @@ -36,6 +37,9 @@ async function validatePipelineSpec(data) {
if (stages) {
yamlObj.stages = stages;
}
if (specTemplate) { // CR-6414 Using specTemplate - skip check spec/stages - they are not used
return { valid: true, message: 'Using specTemplate' };
}
const validatedYaml = yaml.safeDump(yamlObj);
const result = await sdk.pipelines.validateYaml({ yaml: validatedYaml, outputFormat: 'lint' });
let message;
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "codefresh",
"version": "0.78.1",
"version": "0.78.2",
"description": "Codefresh command line utility",
"main": "index.js",
"preferGlobal": true,
Expand Down