Hi all,
is there a way to add a tag to the build from the build task?
Thanks
You can do that at the build at VSO build screen for your build [see below ]

Close this issue if resolved , as it is not an issue for that team :)
thanks.
@gergues I was not referring to labeling the sources.
This are the tags I'm interested in:
I would like to add a tag programmatically from my build task.
Any idea if that is possible?
We're in the process of making the agent capable of using git.exe (instead of libgit)
There's also a checkbox on the definition which says to make the OAuth token available to ad-hoc scripts.
What that adds up to is if you select both of those options, we will stuff the creds into the remote (and remove either at end of prepare or end of build dependending on that check box).
What that means to you is you could write a simple cmd/shell/ps1 script which calls a sequence of git cmds and does a push. It will authenticate and work. We make the commit that's being built available as another variable so if I understand your scenario correctly, it should be trivial.
From: Mario Majcica [email protected]
Sent: Friday, January 22, 2016 9:12 AM
To: Microsoft/vso-agent-tasks
Subject: Re: [vso-agent-tasks] Tagging a build from task (#1113)
@gergueshttps://github.com/gergues I was not referring to labeling the sources.
This are the tags I'm interested in:
[tags]https://na01.safelinks.protection.outlook.com/?url=https%3a%2f%2fcloud.githubusercontent.com%2fassets%2f3026551%2f12512767%2f6b453cbe-c11a-11e5-840f-058e22eea213.PNG&data=01%7c01%7cBRYANMAC%40exchange.microsoft.com%7ccbd292e7831149fd2a3a08d323360a01%7c72f988bf86f141af91ab2d7cd011db47%7c1&sdata=%2bAP1YCWKvT9eWcLgLITKWyLNbadvxkEq95OnRxaRKMM%3d
I would like to add a tag programmatically from my build task.
Any idea if that is possible?
Reply to this email directly or view it on GitHubhttps://github.com/Microsoft/vso-agent-tasks/issues/1113#issuecomment-173930921.
@mmajcica we will add a ##vso[build.tag] command to support your scenarios.
@mmajcica In the meantime until the stuff @bryanmacfarlane mentions (for tagging the repository) is in place, I've put an extension in the store which takes care of putting the credentials into the remote and revert the changes back at the end.
@TingluoHuang thanks. That was something I was looking for. A cmdlet in a Microsoft.TeamFoundation.DistributedTask.Task.Common would be welcome.
Thanks
That would be a nice feature for sure.
Hi. Its been more than 6 months for last comment on this thread. Do we have something of this sort available now? I want to tag a build so that i can choose to trigger different release configurations.
I have built a build task a while ago, if interested, I can share it.
"##vso[build.addbuildtag]" command is available to tasks for this functionality.
@shashban This command functionality should be also available for releases. You can manually add a tag to it but there's no logging command, no API, no nothing.
@andremarques023 We don't have a task command to ad a release tag yet. You can add a tag using update Release API.
I encapsulated the logging command functionality in a task inside this extension: https://marketplace.visualstudio.com/items?itemName=andremarques023.DiagnosticTasks
It would be nice to have this logging command for releases too so the task would work for both.
@
@StephaneBischoff which artifact? Do you mean the release process?
we should have this on log command as we have for build
Most helpful comment
"##vso[build.addbuildtag]" command is available to tasks for this functionality.