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

Template for MSbuild target / task #7548

Open
Tracked by #10733
vlada-shubina opened this issue Apr 19, 2022 · 7 comments
Open
Tracked by #10733

Template for MSbuild target / task #7548

vlada-shubina opened this issue Apr 19, 2022 · 7 comments
Labels
Area: API needs-design Requires discussion with the dev team before attempting a fix. triaged
Milestone

Comments

@vlada-shubina
Copy link
Member

vlada-shubina commented Apr 19, 2022

Extracted from dotnet/templating#233

Create a template for creation of MSBuild tasks and targets.

The template should setup:

  • correct packaging (per the guidance we've created)
  • support for full-framework and .NET versions of MSBuild (for Visual Studio and dotnet build support)
  • should scaffold out folders for the different extensibility points (build vs buildMultitargeting, primarily) with a README in each folder describing the intent)
  • scaffold out tests for the generated Task(s)?
    • may require that we ship the MSBuild Task Testing helpers in the MSBuild project as a separate package first, so it can be easily included
  • Will need a strategy for easy testing locally vs packaged.
@vlada-shubina
Copy link
Member Author

@baronfel please advise whether this issue should be moved to dotnet/msbuild repo instead.

@baronfel
Copy link
Member

Yeah, it should. I've added a couple items to cover in the issue description. But will go ahead and transfer it.

@baronfel baronfel transferred this issue from dotnet/templating Apr 19, 2022
@baronfel baronfel added Area: API needs-triage Have yet to determine what bucket this goes in. and removed need-pm-discussion labels Apr 19, 2022
@danmoseley
Copy link
Member

Perhaps it could ensure that Execute() returns "return !Log.HasLoggedErrors;" as all tasks should.

@benvillalobos benvillalobos added needs-design Requires discussion with the dev team before attempting a fix. and removed needs-triage Have yet to determine what bucket this goes in. labels Apr 28, 2022
@benvillalobos benvillalobos added this to the Backlog milestone Apr 28, 2022
@teo-tsirpanis
Copy link
Contributor

correct packaging (per the guidance we've created)

Where can I find that guidance?

@baronfel
Copy link
Member

@teo-tsirpanis I updated the description with the link, but the example is at https://docs.microsoft.com/en-us/visualstudio/msbuild/tutorial-custom-task-code-generation?view=vs-2022#package-the-task-for-distribution. I've applied them to my own project Ionide.KeepAChangelog.Tasks if you want to see what they look like when applied to a non-example Task.

@teo-tsirpanis
Copy link
Contributor

@rainersigwald
Copy link
Member

rainersigwald commented Sep 30, 2024

Consideration here: pull in the type of improvements mentioned in #5068.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area: API needs-design Requires discussion with the dev team before attempting a fix. triaged
Projects
None yet
Development

No branches or pull requests

7 participants