You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Regarding #4456, it seems like we have an increasing need in the community to affect the input to GitVersion in order to control how it generates its output.
As we already have a set of standardized "output variables", so perhaps we should establish a new concept around "input variables" as well?
These input variables could either be defined as environment variables, or as JSON, just like the output variables currently work. We already have Git_Branch which we need to keep for backwards compatibility, but I think we should namespace the environment variables with GitVersion_ just like we do for the output variables.
Specific use-cases for input variables would be build agent, but eventually I hope that GitVersion can be executed on a static JSON input file (piped from another GitVersion command, as discussed in #2275) and that the static JSON contains absolutely everything required for GitVersion to calculate a version number, regardless of how it's configured. Sort of like:
gitversion prepare → Prepares and validates the JSON input document we are discussing now. This step is optional and can be replaced with a static and guaranteed valid JSON input document.
gitversion execute → Reads the JSON input document, the configuration file, and produces a JSON file representing the current state of the repository.
gitversion calculate → Reads the JSON state file from step 2 and performs the version calculation. The result is a JSON output document.
I'm not set on the naming or details, but I hope the above is sufficient to understand the general idea and to foster further discussions.
The text was updated successfully, but these errors were encountered:
Regarding #4456, it seems like we have an increasing need in the community to affect the input to GitVersion in order to control how it generates its output.
As we already have a set of standardized "output variables", so perhaps we should establish a new concept around "input variables" as well?
These input variables could either be defined as environment variables, or as JSON, just like the output variables currently work. We already have
Git_Branch
which we need to keep for backwards compatibility, but I think we should namespace the environment variables with GitVersion_ just like we do for the output variables.Specific use-cases for input variables would be build agent, but eventually I hope that GitVersion can be executed on a static JSON input file (piped from another GitVersion command, as discussed in #2275) and that the static JSON contains absolutely everything required for GitVersion to calculate a version number, regardless of how it's configured. Sort of like:
gitversion prepare
→ Prepares and validates the JSON input document we are discussing now. This step is optional and can be replaced with a static and guaranteed valid JSON input document.gitversion execute
→ Reads the JSON input document, the configuration file, and produces a JSON file representing the current state of the repository.gitversion calculate
→ Reads the JSON state file from step 2 and performs the version calculation. The result is a JSON output document.I'm not set on the naming or details, but I hope the above is sufficient to understand the general idea and to foster further discussions.
The text was updated successfully, but these errors were encountered: