-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
Command-line option for displaying targets #33
Comments
MSBuild team triage: Do you know about the /pp flag?
|
I was not aware of that flag; thanks for pointing it out. However, I don't believe that the /pp flag really addresses the scenarios I am thinking of. As a developer on a project that uses MSBuild, particularly one that uses more than just the standard build targets (like CoreFX), I want to quickly see what targets are available for me to execute. Scrolling through a large aggregated project file doesn't really serve that purpose. |
I love the idea of having an easy way to display available targets. The
An alternative I currently prefer follows the solution outlined here by using a custom or inline task: Nevertheless it would feel much better if the possibility to display available targets is a built-in feature of msbuild. |
Marking this up for grabs. If someone cares to research the change we may be willing to accept it. I'd probably choose to dump the Target names available to the default/or specified *proj file. One drawback I see is many of the 'common' Targets are not meant for direct consumption and I wouldn't want to encourage folks to use them. |
I started to make some investigation. Here are some results: The necessary changes depend on the behaviour we need. For instance rake lists all available tasks (tasks in rake are the equivalent of targets in msbuild) with a description (descriptions in rake are the equivalent of labels in msbuild). Tasks without description are by default ignored. This way it is possible to have 'private' tasks that are not intended for execution by the user. Gradle has a similar behaviour where tasks without a description are handled differently than ones with a description. Lets break down the necessary changes for this:
The method
Targets without a For point 3 an own issue might be necessary, since at the current point of time I cannot assess the impact of this change. A minimal implementation can however omit point 3. |
This feature would make MsBuild a lot more accessible, so this would be helpful! 👍 |
This sort of caveat makes it painful: |
Fast forward four years and still no listing of targets either in msbuild or in the newer dotnet.exe!! |
Every one moves to CMake. Now! But, seriously, give an intern at Microsoft this perfect first task and a week or two and she will get the |
@AbhishekTripathi to be fair, it's been up for grabs for 4 years. I do not think it would be terribly difficult. |
Most build systems that allow the creation of custom targets also have a command-line option for displaying the available targets in a project:
gradle tasks
rake --tasks
grunt --help
Developers working on projects that use MSBuild would benefit from a similar feature.
The text was updated successfully, but these errors were encountered: