This repository was archived by the owner on May 16, 2025. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 50
Issue#803 #804
Merged
Merged
Issue#803 #804
Changes from all commits
Commits
Show all changes
7 commits
Select commit
Hold shift + click to select a range
f80d77b
Work in progress.
cddde92
Fix the available asp.net core versions to match available sdks. Fix …
0f8976f
Fix a formatting error.
b45481b
Add a test case to hit a otherwise missing line.
0e9bffb
Resolve PR comments.
bd01a29
Move the .NET Core filtering for VS2015 into the GetVs2015AspNetCoreV…
bf2fd7e
Change the restrition on the 1.0 and 1.1 templates to require SDK [1.…
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
50 changes: 50 additions & 0 deletions
50
GoogleCloudExtension/GoogleCloudExtension/VsVersion/ToolsPathProviderBase.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,50 @@ | ||
| using GoogleCloudExtension.Deployment; | ||
| using System; | ||
| using System.Collections.Generic; | ||
| using System.IO; | ||
| using System.Linq; | ||
|
|
||
| namespace GoogleCloudExtension.VsVersion | ||
| { | ||
| internal abstract class ToolsPathProviderBase : IToolsPathProvider | ||
| { | ||
| internal const string SdkDirectoryName = "sdk"; | ||
| internal const string NugetFallbackFolderName = "NuGetFallbackFolder"; | ||
|
|
||
| /// <inheritdoc /> | ||
| public abstract string GetExternalToolsPath(); | ||
|
|
||
| /// <inheritdoc /> | ||
| public abstract string GetDotnetPath(); | ||
|
|
||
| /// <inheritdoc /> | ||
| public abstract string GetMsbuildPath(); | ||
|
|
||
| /// <inheritdoc /> | ||
| public abstract string GetMsdeployPath(); | ||
|
|
||
| /// <inheritdoc /> | ||
| public abstract string GetRemoteDebuggerToolsPath(); | ||
|
|
||
| /// <inheritdoc /> | ||
| public IEnumerable<string> GetNetCoreSdkVersions() | ||
| { | ||
| string dotnetDir = Path.GetDirectoryName(GetDotnetPath()); | ||
| if (dotnetDir == null) | ||
| { | ||
| return Enumerable.Empty<string>(); | ||
| } | ||
| string sdkDirectoryPath = Path.Combine(dotnetDir, SdkDirectoryName); | ||
| if (!Directory.Exists(sdkDirectoryPath)) | ||
| { | ||
| return Enumerable.Empty<string>(); | ||
| } | ||
| Version dummy; | ||
| return Directory.EnumerateDirectories(sdkDirectoryPath) | ||
| .Select(Path.GetFileName) | ||
| .Where( | ||
| sdkVersion => | ||
| sdkVersion.StartsWith("1.0.0-preview") || Version.TryParse(sdkVersion, out dummy)); | ||
| } | ||
| } | ||
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Another wrench thrown your way, the latest SDK is actually
1.1.4and covers both .NET Core runtime 1.0 and 1.1. I think that you are going to have to create a table to codify the releases here, with what versions of .NET Core they target, etc...There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This comment is not accurate, your logic (looking for .NET Core SDK between
1.0.xto2.0.x) works perfectly.