Skip to content

Commit

Permalink
Included workflow displayName expression and context get (#119)
Browse files Browse the repository at this point in the history
Co-authored-by: Guilherme Zanini <gui_rz@hotmail.com>
  • Loading branch information
guilhermezanini-harness and guirociozanini authored Jun 13, 2024
1 parent b5f0f10 commit 4bc7f42
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions expressions.go
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,7 @@ var ExpressionsMap = map[string]string{
"app.accountId": "<+account.identifier>",
"pipeline.name": "<+pipeline.name>",
"workflow.name": "<+stage.name>",
"workflow.displayName": "<+stage.name>",
"workflow.description": "<+stage.description>",
"workflow.releaseNo": "<+pipeline.sequenceId>",
"workflow.pipelineResumeUuid": "<+pipeline.executionId>",
Expand Down Expand Up @@ -162,6 +163,9 @@ var DynamicExpressions = map[string]interface{}{
"configFile.getAsString(": func(key string) string {
return "<+configFile.getAsString(\"" + TrimQuotes(formatString(key)) + "\")>"
},
"context.get(": func(key string) string {
return "<+exportedVariables.getValue(\"" + TrimQuotes(formatString(key)) + "\")>"
},
}

func formatString(key string) string {
Expand Down

0 comments on commit 4bc7f42

Please sign in to comment.