question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Unable to find msbuild.

See original GitHub issue

I am trying to run this action on a self-hosted runner.

- name: Add msbuild to PATH
  uses: microsoft/setup-msbuild@v1.0.0
    with:
      vs-version: 15.0

Here’s the output:

“C:\Program Files (x86)\Microsoft Visual Studio\Installer\vswhere.exe” -version 15 -requires Microsoft.Component.MSBuild -find MSBuild**\Bin\MSBuild.exe ##[error]Unable to find msbuild.

I tried doing the following, but it says it expects string, number, or boolean, not an array.

vs-version:
  [15.0,15.9]

I have Visual Studio Build tools installed on this server.

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:5 (2 by maintainers)

github_iconTop GitHub Comments

2reactions
ranjjose-chazcommented, Jul 28, 2020

I’m too stuck with the same issue: This is from my GitHub-actions yml file: (hosted on aws)

- name: Dependency - MSBuild
  uses: microsoft/setup-msbuild@v1.0.1
  with:
    vswhere-path: 'C:\Program Files (x86)\Microsoft Visual Studio\Installer'  

resulting in the error in the step:

Run microsoft/setup-msbuild@v1.0.1 “C:\Program Files (x86)\Microsoft Visual Studio\Installer\vswhere.exe” -products * -requires Microsoft.Component.MSBuild -property installationPath -latest ##[error]Unable to find MSBuild.

I did add MSBuild location in the system path variable as well.

What am I missing? Thanks for the consideration

0reactions
caibinwav123456commented, May 21, 2021
Read more comments on GitHub >

github_iconTop Results From Across the Web

##[warning]Unable to find MSBuild: Version = 15.0
Hi,. I have VS2017 installed on my OnPremises BuildAgent for TFS 2017 server and I have selected Visual Studio 2017 in my build...
Read more >
visual studio 2017 - MSBuild.exe not found, cmd.exe
I recently installed Visual Studio 2017, shouldn't MSBuild.exe come with it? One of bash scripts is calling it, but can't find anything.
Read more >
Where to Find MSBuild.exe - C# 411
Developers use MSBuild to build a Visual Studio project or solution file from a command line, batch file, build tool, or automated script....
Read more >
Walkthrough: Using MSBuild - Microsoft Learn
In the Visual Studio installer, navigate to Individual Components, and locate the checkbox for MSBuild. It is automatically selected when you ...
Read more >
Locating MSBuild on a machine - Meziantou's blog
MSBuild is part of the Visual Studio. If you want to write a CI/CD pipeline for your project, you will need to find...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found