DioBrando
DioBrando

Reputation: 1017

Build/Publish .NET Core 3.x application with TFS 2018 Update 3.2

I have an application that uses .NET Core 3.1 but in .NET Core Build and Publish tasks, the dropdown menu offers only 'til 2.x version. TFS pipeline

How am I supposed to use them or what workaround instead? Simple CLI?

Thanks in advance

@Patrick .NET Core Task is this right? enter image description here

But how should be that different compared to Restore/Build/Publish that are aldready set up in .NET Core pipeline?

If that so, I guess I just need to set the command with my custom publish value:

dotnet publish myPath -c release -f netcoreapp3.0 --self-contained true -r win-x64

Am I right?

Upvotes: 0

Views: 1509

Answers (2)

PatrickLu-MSFT
PatrickLu-MSFT

Reputation: 51153

That's not stand for .NET Core Version. It's our task version in Azure DevOps build Pipeline.

Tasks are versioned, and you must specify the major version of the task used in your pipeline. This can help to prevent issues when new versions of a task are released.

Each task in a pipeline has a Version selector to let you choose the version you want.

Source Link: Task versions

According to your TFS tag, seems you are using private agent. You could choose to pre-install your .NET Core related environment/SDK in the agent manually.

If you want to do this during the pipeline, you should use Use .NET Core task

Use this task in a build or release pipeline to acquire a specific version of .NET Core from the Internet or the tools cache and add it to the PATH.

Not sure which TFS version you are using, which may do not contain above task. You could choose to manually pre-install .NET Core related on the agent or download source of task code and package upload to TFS server or use 3-rd party extension instead.

Upvotes: 2

Daniel Mann
Daniel Mann

Reputation: 59045

That's the version of the task, not the version of .NET Core.

Upvotes: 1

Related Questions