Variables
You can customize some steps with variables—pieces of context that Knope can substitute into strings.
You configure variables with both the string to replace and the name of the variable that
will replace it. For example, if you wanted to insert the current package
version into a command, you might use a {"version": "Version"} variable config. This would replace any instance
of the string version with Version.
Defaults
Section titled “Defaults”Any part of knope.toml which can accept variables will replace the following variables by default.
Anywhere the string on the left appears in the content, Knope will replace it.
$version:Version$changelog:ChangelogEntry
These defaults are only in place if custom variables aren’t defined. To disable to defaults, define variables, even as an empty map:
[[workflows.steps]]type = "Command"command = "echo $version"variables = {} # Disable default `$version` variable substitutionVersion
Section titled “Version”Version will try to parse the current package version.
ChangelogEntry
Section titled “ChangelogEntry”ChangelogEntry is the content of the changelog (if any) for the version in the Version variable.
IssueBranch
Section titled “IssueBranch”IssueBranch will produce the same branch name that the SwitchBranches step would produce. You must have already
selected an issue in this workflow using SelectJiraIssue, SelectGitHubIssue, or SelectIssueFromBranch before
using this variable.