-
Notifications
You must be signed in to change notification settings - Fork 654
Adds /version switch #1155
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
Adds /version switch #1155
Conversation
The version of GitVersion is now displayed if the /version switch is provided. The version is also included in the help page.
@kjjuno: Awesome! Do you think it would be possible to add a test or two for this as well? |
For sure. I'll add some when I get a chance |
For some reason the travis-ci build seems to be hung. Is there a way to kill it and start over. Did I do something in my unit tests that isn't supported on travis? |
@kjjuno: I dunno what happened. I restarted the build now. |
I'm guessing the dynamic assembly compile stuff doesn't work on linux. I may have to think of a different test. |
I resolved the build issue by preventing this test from running on mono. The test compiles an assembly at runtime with a specific version, and then tests that the version is correct. The dynamic compilation code is not supported on mono. |
@kjjuno: Perhaps you can use Mono.Cecil to compile the assembly instead? That should work on Mono just fine. |
I've never used that before. I'll learn how to do that and update the pr |
{ | ||
var definition = new AssemblyNameDefinition("test-asm", fileVersion); | ||
|
||
var asmDef = AssemblyDefinition.CreateAssembly(definition, "test-asm", ModuleKind.Dll); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice work figuring out how to do this, nice solution
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I could never het the linux travis ci to build. Did that ever get resolved?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It didn't actually, I didn't notice that before merging. I likely will just not run this test on Mono. Thoughts @asbjornu
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@JakeGinnivan: Running the build now to see what's up.
Welcome back Jake! |
Thanks @ghuntley, first weekend in a month without a wedding or a bucks party on :) |
Closes #947
The version of GitVersion is now displayed if the /version switch is provided. The version is also included in the help page.