Can we create release number as "Nuget package version number - channel Name"

Hi Team,

is there any way to create the release number as “NuGetPackageVersion-channelName”. Do we have any template or variable??

we have multiple channels and we are deploying same Nuget package to all the channels and we are having issues in creating release numbers for each channel. Can someone please help me.

Thank you.

1 Like

Hi Kishore,

Thanks for getting in touch! in 3.2.17 we added a new variable available at the release creation for Octopus.Release.Channel.Name.
Currently we don’t have a way to match this with a package, but it could be used with the previous channel versions that were also added: Octopus.Version.Channel.(Last|Next)(Major|Minor|Patch|Build|Revision|Suffix)
Would these help? I can find out about if the package version can be made available at release creation.

Let me know what you think,
Vanessa

Hi Vanessa,

Thanks for the reply.
Octopus.Release.Channel.Name>>this will work. But actually we also need Nuget package version number template/variable. Because we want to keep the release number as combination of Nuget package version number and channel name.
we are deploying same version to multiple channels so we want to track the version number in the release number.

Please help me if there is any variable I can use in the release creation.

Thanks,
Kumar

Hi Kumar,

It isn’t a variable that we have available at the release creation time. I will bring it up with the team however as we are introducing more features to use a pre-release tag in versions.
I’ll get back to you with the outcome.

Vanessa

Thank you so much Vanessa. Awaiting for your response. Thanks.

Hi Kumar,

Are you creating your packages named this way? Because it does work if you use the ‘Use the version number from an included NuGet package’ setting in the project settings.
Did you try this?

Vanessa

Hi Vanessa,

Yes, I’m creating in the same way (‘Use the version number from an included NuGet package’).
But we have created 20 channels and we are using same Nuget package to deploy. we are having issues in creating release numbers for multiple channels.

for example:
Nuget package version is = 1.1.36
i) when I select Channel1, I want my release number as 1.1.36-Channel1
ii) when I select Channel2, I want my release number as 1.1.36-Channel2
iii) when I select Channel3, I want my release number as 1.1.36-Channel3

finally my release number format should be like “Nuget package version-ChannelName” .

is there any way we can make the release number in this format?

Thanks,
Kumar

Hi Kumar,

I would have to suggest that you put this on UserVoice. https://octopusdeploy.uservoice.com/
It isn’t a simple straight forward change. Majority of projects have more than one package, so then on release creation we would need to have a set of variables potentially for each package. Release creation isn’t when we do a lot of variable expansion, and you can also define a package via a variable. So this becomes very complex very quickly. We would need to see community support for this feature expansion to put the time into it.

Thanks for explaining your scenario.
Vanessa

I see. Thanks for the reply Vanessa. Sure. I will put this on UserVoice.

Hi Vanessa,

it will be great if you add a information about Octopus.Release.Channel.Name and other system variables with ‘Channel’ to the page http://docs.octopusdeploy.com/display/OD/System+variables

I found this topic from google!

Thanks,
Vitaliy

Hi Vitaliy,

We have added the release channel name but we will create a new page around release version templates. As those variables don’t belong to deployment.
Thank you for the feedback!

Thanks,
Daniel