-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Feature] Change Cli to a new implementation #34
Comments
@arturcic what does |
does gitversion --version output the verison of gitversion itself - or is that meant to trigger the version calculation? |
|
|
Do you think we could leave out |
we can |
as for |
of this one |
for that we can use this https://github.com/dotnet/command-line-api/wiki/How-To#Middleware-Pipeline |
ok [convert] looks like a nice feature to have, one to implement probably seperately after all the core commands are done |
or we can have something like |
Given |
Yes, and this will help those using version 5.3.x migrate to 6.0 |
agree |
Yep |
but this is just enhancing the current cli. What we've discussed on the slack channel is different - in that case we change the approach - use the tool in pipeline mode |
Yeah. Do you think we should have a seperate command like |
I don't know, I prefer to have in explicit - similar to |
Ok. So the list of commands something like:
Everything else is a tool that will take the version variables from somewhere and do something with them. |
Well compat could involve calling the output consuming tools as currently Gitversion does that |
Can we leave out compat for now then? I'm not actually sure what it does, I understand convert will take the old sytax and parse it to the new syntax (assuming there is enough info in the old syntax to do that) - so does compat take the new sytnax and convert it to the old? |
The idea of compat is that let's say you have Gitversion version 5.3.2. you update to 6.0.0 and just add [compat] and it should work. Not sure how easy will it be to implement that, but this one might call [convert] internally |
Ok. Sounds like potentially one we could leave from the core task of getting everything in place, and could come as an enhancement afterwards.. I've posted to slack channel a bit about writing version variables to STDOUT using a control syntax when logging is also enabled to write to STDOUT. Then a
In this example you might store the output in a variable and write it to the console before piping on to sanitise for it to be useful. We could also show examples of the variables being converted to different formats
Although not sure how much value there is in that. |
Might be good to offer a tool that can take the version variables as input but then select / write a specific one as output. I believe the old command line has this ability to only output a particular named version variable value. Although... for powershell users, it would already be very easy for them to output the version variables json into a json object and select just the property they want. Not sure how difficult that would be in other shells. |
Yes, it's called
With jq, I think it's even simpler than it is with PowerShell. :) |
This issue has been automatically marked as stale because it has not had recent activity. After 30 days from now, it will be closed if no further activity occurs. |
Change the Cli to System.Commandline
The commands:
gitversion --help
gitversion --version
gitversion config (the current init)
gitversion remote --user, --token, --pawwsord, --url - this will work as dynamic repo will download the repo, then you can gitversion run (for remote repos you need 2 steps, remote and run)
gitversion run --config --verbosity --noFecth --noNormalize --args:assemblyInfo=true --args:wixfile=somefile
gitversion run --args:assemblyInfo=true --args:assemblyInfoFile="file1" --args:assemblyInfoFile="file2"
gitversion normalize
gitversion [compat] /updateAssemblyVersion /config - this will allow old syntax with [compat]
gitversion [convert] /updateAssemblyVersion /config this will output the corresponding new syntax
The text was updated successfully, but these errors were encountered: