-
Notifications
You must be signed in to change notification settings - Fork 3
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
Targets in Directory.Build.targets or .props not shown #69
Comments
Where are those files located? MsBuildTaskExplorer scans the solution folder only. |
They're outside the solution folder. That explains the issue. |
@solvingj if MsBuild itself understands your files in that folder, maybe it is worth scanning that (and similar ones) folder as well. Just let me know if you are interested in that and we can support it somehow. |
Thanks for taking an interest. If you haven't read about them already, here's an overview of the files I was using: https://docs.microsoft.com/en-us/visualstudio/msbuild/customize-your-build?view=vs-2019 It does probably make sense to support them if it's not too difficult. |
Thanks for the link, looks like we should go to the root level by level
|
Yes that seems like one way you could approach it. To be honest though, I'm surprised there's no internal project API for enumerating all loaded targets regardless of the props file they're in, and/or enumerating all props file's that have been loaded during evaluation phase. If you haven't looked for such a thing already, perhaps consider it. |
I totally agree, I even thought that we do something like that but based on what I saw, when I was checking, we just look for the files manually. Thank you for highlighting it, hope there is a way to do it like you said. |
thanks for all your hard work! |
If a custom target is defined in either of the following implicitly imported files, it does not appear in
MsBuildTaskExplorer
Directory.Build.targets
Directory.Build.props
If instead, I move the target definition to a separate
.targets
file and import that targets file inDirectory.Build.targets
, it is shown properly.The text was updated successfully, but these errors were encountered: