Skip to content
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

Support YYYY, MM, DD variables in version templates #894

Closed
nblumhardt opened this issue May 1, 2014 · 4 comments
Closed

Support YYYY, MM, DD variables in version templates #894

nblumhardt opened this issue May 1, 2014 · 4 comments
Labels
kind/enhancement This issue represents an enhancement we are committed to adding to Octopus as some time
Milestone

Comments

@nblumhardt
Copy link
Contributor

http://help.octopusdeploy.com/discussions/questions/2276-release-versioning-parameters

E.g.

Octopus.Date.Year
Octopus.Date.MonthNumber
Octopus.Date.DayNumber
@nblumhardt nblumhardt added this to the 2.5 milestone May 1, 2014
@dtjensen
Copy link

dtjensen commented May 1, 2014

Nick - I have used other date-based versioning in the past as well like "day in year", etc. So, when you guys think about this one, you may want to think bigger than the few examples I listed in the original question.

Actually, if there is a way to allow entering a powershell scriptlet that could yield a result in the form of a variable, that may be the most flexible long term solution. Because people use lots of schemes when creating their version numbers. Just a thought...

@nblumhardt
Copy link
Contributor Author

Thanks for the ideas - was planning to spend a bit of time thinking through other options.

Running PS at this point may not be viable, but extending the Octopus variable syntax with simple expressions is a possibility at some point. Guess we'll collect some more scenarios as we go.

@PaulStovell
Copy link
Member

Done in 2.5:

#{Octopus.Date.Year}.#{Octopus.Date.Month}.#{Octopus.Date.Day}.#{Octopus.Date.DayOfYear}

Output:

2014.06.16.167

Month and Day are always 2 chars. Day of year is variable length.

@lock
Copy link

lock bot commented Nov 28, 2018

This thread has been automatically locked since there has not been any recent activity after it was closed. If you think you've found a related issue, please contact our support team so we can triage your issue, and make sure it's handled appropriately.

@lock lock bot locked as resolved and limited conversation to collaborators Nov 28, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
kind/enhancement This issue represents an enhancement we are committed to adding to Octopus as some time
Projects
None yet
Development

No branches or pull requests

3 participants