1
0
mirror of https://github.com/SAP/jenkins-library.git synced 2025-03-03 15:02:35 +02:00

add deprecation warning (#4691)

Co-authored-by: Gulom Alimov <gulomjon.alimov@sap.com>
This commit is contained in:
Googlom 2023-11-23 13:42:02 +05:00 committed by GitHub
parent 9596f546c0
commit 0d6fb16034
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 6 additions and 0 deletions

View File

@ -92,6 +92,9 @@ func checkIfStepActive(utils piperutils.FileUtils) error {
runSteps = runConfigV1.RunSteps runSteps = runConfigV1.RunSteps
runStages = runConfigV1.RunStages runStages = runConfigV1.RunStages
} else { } else {
log.Entry().Warning("This step is using deprecated format of stage conditions which will be removed in Jan 2024. " +
"To avoid pipeline breakage, please call checkIfStepActive command with --useV1 flag.",
)
runConfig := &config.RunConfig{StageConfigFile: stageConfigFile} runConfig := &config.RunConfig{StageConfigFile: stageConfigFile}
err = runConfig.InitRunConfig(projectConfig, nil, nil, nil, nil, doublestar.Glob, checkStepActiveOptions.openFile) err = runConfig.InitRunConfig(projectConfig, nil, nil, nil, nil, doublestar.Glob, checkStepActiveOptions.openFile)
if err != nil { if err != nil {

View File

@ -81,6 +81,9 @@ func getDefaults() ([]map[string]string, error) {
var yamlContent string var yamlContent string
if !defaultsOptions.useV1 { if !defaultsOptions.useV1 {
log.Entry().Warning("This step is using deprecated format of stage conditions which will be removed in Jan 2024. " +
"To avoid pipeline breakage, please call getDefaults command with --useV1 flag.",
)
var c config.Config var c config.Config
c.ReadConfig(fc) c.ReadConfig(fc)