I’d like to calculate a path in a MsBuild task, to be used by another MsBuild task.
What is the best way to accomplish this?
Setting a environment variable, printing to Console, …?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Use a property or an item. Your MSBuild that calculates the path, return it as a property and you use this property as input for your other task.
If you need to pass a value between two MSBuild project, you should create a third one that will call the other using MSBuild Task and use the TargetOutputs element to get back the value that you want.