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

comand-line build instructions clarification #533

Closed
wants to merge 14 commits into from
Closed
12 changes: 8 additions & 4 deletions README.md
Expand Up @@ -144,10 +144,14 @@ To build the Open XML SDK

If you want to use a command line approach:

1. Go to the directory that contains the solution.
1. Run `dotnet restore` in the directory.
1. Run `dotnet test DocumentFormat.OpenXml.Tests` to run the tests.
1. Run `dotnet pack DocumentFormat.OpenXml` to generate a nupkg.
* Go to the directory that contains the solution.
* Run `dotnet restore` in the directory (only if using .NET Core SDK version less than 2.1).
* Run `dotnet test DocumentFormat.OpenXml.Tests.csproj` to run the tests.
* Run `dotnet pack .\src\DocumentFormat.OpenXml\DocumentFormat.OpenXml.csproj` to generate a nupkg.
* Run `dotnet build` to build the SDK and test projects

By default, `dotnet` will build/test/run only the .NET Core target framework. To build all target frameworks, set the ProjectLoadStyle environment variable: `ProjectLoadStyle=All` To see the other values for `ProjectLoadStyle`, please refer to the comments in [Directory.Build.Props](Directory.Build.Props). NOTE: Because the other frameworks will be targeted (like .NET 4.6) when using `ProjectLoadStyle=All`, msbuild.exe is needed instead of dotnet.exe so refer to [appveyor.yml](appveyor.yml) to see the appropriate command lines.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it's actually only because of .NET 3.5; .NET 4.0+ works fine with the dotnet cli. Also, the .exe isn't really needed, and is technically incorrect on *nix platforms.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it's actually only because of .NET 3.5; .NET 4.0+ works fine with the dotnet cli. Also, the .exe isn't really needed, and is technically incorrect on *nix platforms.



Related tools
-------------
Expand Down