Commit graph

1805 commits

Author SHA1 Message Date
William Lee
55f62d9d64
Add install tool command (#8132)
* compose all the parts

* Fix on obtain and shim maker for better end to end experience
  * Fix error when there is space in the middle of path of nuget config
  * Fix path in profile.d is the tmp home path during install
  * better handle of ~home
  * remove profile.d file in uninstall script
  * Fix test since it looks up current directory
  * folder structure inside nupkg to tools/TFM/RID/mytool.dll
  * Add check for config file existence
  * Rename name space to Microsoft.DotNet.ShellShim
  * Rename name space to Microsoft.DotNet.ToolPackage
2017-12-04 14:13:24 -08:00
Peter Huene
4f7c76b4e4 Make --no-build imply --no-restore for run command.
This commit makes the `--no-build` option for the run command
automatically imply `--no-restore`.

Fixes issue #7472.
2017-11-28 16:01:18 -08:00
Peter Huene
ea85555a97 Add verbosity option to run command.
This commit adds the verbosity option to the run command.

This will be used in tests for visibility into what the run command is
doing.

The default verbosity is unaffected.

Fixes issue #7932.
2017-11-28 16:00:36 -08:00
Peter Huene
40b0e0fcec Make --no-build imply --no-restore for pack command.
This commit makes the `--no-build` option for the pack command
automatically imply `--no-restore`.

Fixes issue #7472.
2017-11-27 23:53:22 -08:00
Peter Huene
de10b22bcd Make --no-build imply --no-restore for test command.
This commit makes the `--no-build` option for the test command
automatically imply `--no-restore`.

Fixes issue #7472.
2017-11-27 23:06:48 -08:00
William Lee
cc80ed43e0
Tools shim maker and env path handling (#8085)
* Tools shim maker and env path handling

Includes component:

* Given executable, create shim (all three OSs)
* Add executable path to Env PATH during first run
* including manual instruction when there is no access
2017-11-27 10:45:43 -08:00
Livar
1239b21477
Merge pull request #8082 from peterhuene/fix-sln-remove-dependencies
Remove project dependencies when removing a project from a solution.
2017-11-21 21:52:26 -08:00
William Lee
584d3f0502
Global tools package obtain (#8035)
Add ExeutablePackageObtainer

Given a tools package id, it can create a fake project and restore to correct folder

- DI, aka no circular dependency of commands
- Parser of config XML
- I try to create test nupkg at build time, so I can run test and debug
easily with VSCode. The code is in test csproj.
2017-11-21 20:10:06 -08:00
Peter Huene
6210dab09c Remove project dependencies when removing a project from a solution.
This commit fixes #6198.

When a project is removed from a solution using the `sln remove`
command, any projects in the solution with a project dependency (note:
this is different from a project reference) on the project should have
the project removed as a dependency.

The fix is to scan the projects in the solution and remove any
dependencies on the projects being removed.  If the dependencies section
is empty after the remove, we skip serialization of the section like
Visual Studio does.
2017-11-21 18:20:05 -08:00
William Li
8c3b640540 Fix merge 2 2017-10-31 13:37:28 -07:00
Livar
2031c9cf33
Merge branch 'master' into merges/release/15.5-to-master-20171031-070033 2017-10-31 10:15:11 -07:00
Nick Guerrera
cd489a356a
Merge pull request #7896 from nguerrera/one-process-restore
Use msbuild /restore instead of a separate process
2017-10-27 15:33:09 -07:00
William Lee
cef9a90ad1
Hashed telemetry and event name change (#7919) 2017-10-27 10:58:25 -07:00
Nick Guerrera
35b7ad2789 Use msbuild /restore instead of separate invocations where possible
It is not currently possible when there is a -f|--framework argument because
we cannot force a TargetFramework global property on to the restore evaluation.
Doing so completely breaks restore by applying the TargetFramework to all
projects transitively. The correct behavior is to restore for all frameworks,
then build/publish/etc for the given target framework. Achieving that still
requires two distinct msbuild invocations.

This also changes the verbosity of implicit restore from quiet to that
of the subsequent command (default=minimal). Similar to global properties,
we cannot specify a distinct console verbosity for the /restore portion of
the overall execution. For consistency, we apply the same verbosity change
to the case where we still use two separate msbuild invocations.

This also fixes an issue where the separate restore invocation's msbuild log
would be overwritten by the subsequent command execution. However, this remains
unfixed in the case where we still use two separate msbuild invocations.
2017-10-26 16:01:34 -07:00
Nick Guerrera
8fead788d7 Fix dotnet build /clp:NoSummary 2017-10-26 06:37:45 -07:00
Nick Guerrera
20b0b820a8 Remove unnecessary handling of verbosity in RestoreCommand
We were taking care to set the console verbosity to minimal, but
only when no verbosity argument is passed. However, the default
verbosity for all CLI msbuild commands is already minimal and so
we can just get out of the way.
2017-10-24 15:04:24 -07:00
Peter Huene
03f0c51292 Fix relative path handling on Windows.
On Windows, `PathUtility.GetRelativePath` was not properly handling
paths that differed by case in the drive reference (e.g. "C:\" vs.
"c:\").  The fix was to add the missing case-insensitive comparison
argument.

Replaced uses of `PathUtility.GetRelativePath` with
`Path.GetRelativePath` where possible (requires 2.0.0+).

Additionally, `PathUtility.RemoveExtraPathSeparators` was not handling
paths with drive references on Windows.  If the path contained a drive
reference, the separator between the drive reference and the first part
of the path was removed.  This is due to `Path.Combine` not handling
this case, so an explicit concatenation of the separator was added.

This commit resolves issue #7699.
2017-10-24 11:23:52 -07:00
Livar Cunha
e1916cc4dc Merge remote-tracking branch 'dotnet/release/15.5' into merges/release/15.5-to-master-20171016-070031
* dotnet/release/15.5: (21 commits)
  Manually merging some changes that git merged wrong and deleted from the 15.5 branch.
  Separating the 'legacy' URL construction from the 'current' URL construction methods and logic.
  Use temporary path for fake deps.json in test
  Use same build number for roslyn and F# satellites
  Updating Roslyn satellites and SDK versions
  Insert NuGet Build 4.5.0-preview2-4529 into cli
  Update NuGet to 4529 (signed)
  MSBuild 15.5.154
  MSBuild 15.5.153
  removed commented out config I'd meant to remove
  added a way to specify the asp.net template versions
  Porting 'dotnet-install.sh' from CLI:master to CLI:release/2.0.0
  'NuGet.master.config' does not appear to be used.
  Fixed tests
  Update branch info to release/15.5
  Updating the websdk version to 2.0.0-rel-20171010-665
  Insert NuGet Build 4.5.0-preview1-4526 into cli
  Update DependencyVersions.props
  Updated version of TestPlatform to 15.5.0-preview-20170923-02
  MSBuild 15.4.8
  ...
2017-10-16 15:42:40 -07:00
Livar Cunha
27aa698710 Manually merging some changes that git merged wrong and deleted from the 15.5 branch. 2017-10-13 09:56:08 -07:00
Livar Cunha
1943ddc57f Merge remote-tracking branch 'dotnet/release/2.0.0' into merges/release/2.0.0-to-release/15.5-20171013-070028
* dotnet/release/2.0.0:
  Use temporary path for fake deps.json in test
  Porting 'dotnet-install.sh' from CLI:master to CLI:release/2.0.0
  'NuGet.master.config' does not appear to be used.
  Reverting previous change to: 'NuGet.master.config'
  Moving the runtime version to 2.0.0 for the SDK.
  Revert release/2.0.0 back to 1bcee43995
  Adding the unified transport NuGet feed.
  Keeping the branding for release/2.0.0 at 2.0.3.
  MSBuild 15.4.8
  Insert SDK 2.0.2-vspre-20170927-1
2017-10-13 09:04:58 -07:00
Nick Guerrera
e59fd7af46 Use temporary path for fake deps.json in test
(cherry picked from commit 796b4a06e7)
2017-10-12 16:32:12 -07:00
faahmad
273f4bc4a5 Fixed tests 2017-10-11 12:21:59 +05:30
Livar Cunha
fead8521c3 Moving the runtime version to 2.0.0 for the SDK.
(cherry picked from commit e24b53dda7)
2017-10-09 13:59:09 -07:00
Nick Guerrera
ddae0875cf Revert release/2.0.0 back to 1bcee43995
There were incorrect merges from release/15.5 to release/2.0.0 since then
2017-10-09 13:55:13 -07:00
Nick Guerrera
796b4a06e7 Use temporary path for fake deps.json in test 2017-10-06 10:53:21 -07:00
Livar Cunha
e24b53dda7 Moving the runtime version to 2.0.0 for the SDK. 2017-10-03 16:46:15 -07:00
Ashley Hauck
97b027b232 Remove CscToolPath 2017-10-02 12:26:52 -07:00
Jan Vorlicek
90e217831b Enable RHEL 6 support
This change enables RHEL 6 support. It also adds a new command line option to the
run-build.sh script that enables passing in a folder containing a bootstrap CLI.
This helps in bringup of new target platforms.
2017-09-21 15:20:55 +00:00
Livar
d624a96a1f Merge pull request #7663 from livarcocc/move_testframework_from_output
Removing Microsoft.DotNet.TestFramework from the product code
2017-09-15 15:31:31 -07:00
Livar Cunha
3efd44f935 Removing Microsoft.DotNet.TestFramework from the product code and from the SDK deployment and moving the code to the test folder. 2017-09-15 09:49:19 -07:00
William Li
9c1fa7c9d9 Do not move forward if there is parsing error 2017-09-12 16:54:51 -07:00
Livar
a8dd209359 Merge branch 'master' into merges/release/2.0.0-to-master-20170907-070027 2017-09-07 11:11:28 -07:00
Livar Cunha
093512a64e Pinning the package version expected by NewProjectRestoresCorrectPackageVersion to 2.0.0. 2017-09-06 15:40:31 -07:00
Livar Cunha
cbc87958cc Fix implicit Microsoft.NetCore.App version test. 2017-09-06 12:52:19 -07:00
Daniel Plaisted
97b7553e31 Rename output folder from out to bin 2017-09-01 16:43:02 -07:00
Daniel Plaisted
27dc8032dd Fix test that depended on old output directory layout 2017-09-01 13:53:17 -07:00
Daniel Plaisted
9b331673fe Merge upstream changes 2017-09-01 13:17:40 -07:00
Nick Guerrera
f4f5100af1 Merge pull request #7480 from mikkelbu/list-store-and-help-as-commands
Add store and help to SDK commands
2017-09-01 12:48:58 -07:00
Nick Guerrera
03293f5b90 Fix test expectation for package restored n new project 2017-08-31 17:56:15 -07:00
seancpeters
7f3c93cd0c fixed the bug annotation 2017-08-31 16:40:28 -07:00
seancpeters
bb90633cad annotated the commented out test cases related to netstandard2.0 2017-08-31 16:38:33 -07:00
seancpeters
ffdccdfc21 Re-enabling some unit tests that were skipped, but are again valid with net core 2.1 2017-08-31 15:31:44 -07:00
seancpeters
99489cf402 fixed indentation on Nuget.tempaspnetpatch.config 2017-08-31 10:49:37 -07:00
Daniel Plaisted
4c3b13e4a8 Use a shorter path for test working directories, get rid of Stage 0 project.json based CLI 2017-08-29 17:59:34 -07:00
seancpeters
79e94eb908 Updating new templates to 2.1.0 versions 2017-08-29 15:21:13 -07:00
Daniel Plaisted
9fb5f746ae Fix multiple tests using same output path 2017-08-29 11:26:28 -07:00
Daniel Plaisted
dcb3a7ade7 Use shorter output paths to avoid max path issues on Windows
For example, "out/2" instead of "artifacts/stage2"
2017-08-29 06:55:43 -07:00
Mikkel Nylander Bundgaard
607f72983c Correct unit test 2017-08-29 11:48:53 +02:00
Matt Galbraith
1156e52eb8 Update dependency version 2017-08-28 13:14:23 -07:00
Daniel Plaisted
107252ebe7 Merge upstream changes 2017-08-28 11:09:19 -07:00