-
Notifications
You must be signed in to change notification settings - Fork 527
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
Proper runtime support #2255
Merged
cloudRoutine
merged 31 commits into
fsprojects:fix_dotnetcore
from
matthid:add_runtime_support
Apr 19, 2017
Merged
Proper runtime support #2255
Changes from 21 commits
Commits
Show all changes
31 commits
Select commit
Hold shift + click to select a range
4de3516
add rid and graph parameters
matthid b99bc0b
add parsing of the runtime graph
matthid e916e0d
implement merge
matthid 25e4c4a
add newtonsoft json dep to unit test project
matthid 2db9f1f
use vs2017 image for F# 4.1 support
matthid 51a4768
use F#4.1 for paket.core
matthid deb17ce
commit what I have for now
matthid 554a503
commit the current idea
matthid 898d42e
combine resolutions
matthid 4b0c411
make it build on netcore as well
matthid 320151f
fix build of test projects
matthid 8f0435a
fix unit tests
matthid 244cb1a
fix more real-life tests
matthid b5a96a2
add comment
matthid 981e0e3
Merge branch 'fix_dotnetcore' into add_runtime_support
matthid c71d62b
add comments to RuntimeGraph
matthid 1af9f33
make local nuget feeds work as well.
matthid 90aada1
some cleanup
matthid db0fe01
update netcore project file :/
matthid 80dbd1b
add some tests for runtime dependency resolution.
matthid 88b2430
add runtime dependencies to the lockfile and mark them with 'isRuntim…
matthid d717814
move InstallModel.fs after RuntimeGraph.fs as we will shortly depend …
matthid 5b50f8e
cleanup InstallModel again and prepare for runtime support...
matthid dad17ae
write some release notes
matthid e81cda9
more runtime support in installmodel
matthid 2a4eb54
appveyor, please build a package for me and publish it.
matthid 35e28f3
finish runtime support in installmodel, fix exlude support
matthid 48515bd
cleanup and fixup of 'should understand aot in runtimes' test
matthid 9743b21
make two builds: one which fast publishes the package and one which r…
matthid 3473281
tell appveyor that this are nuget packages.
matthid 71673ce
verbose is a bit too much
matthid 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 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 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 |
---|---|---|
@@ -1,3 +1,4 @@ | ||
image: Visual Studio 2017 | ||
init: | ||
- git config --global core.autocrlf input | ||
build_script: | ||
|
This file contains 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 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 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 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 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 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 |
---|---|---|
|
@@ -107,7 +107,12 @@ module LockFileSerializer = | |
{ package.Settings with FrameworkRestrictions = FrameworkRestrictionList [] } | ||
else | ||
package.Settings | ||
let s = settings.ToString().ToLower() | ||
let s = | ||
// add "isRuntimeDependency" | ||
match package.IsRuntimeDependency, settings.ToString().ToLower() with | ||
| true, "" -> "isRuntimeDependency: true" | ||
| true, s -> s + ", isRuntimeDependency: true" | ||
| _, s -> s | ||
|
||
if s = "" then | ||
yield sprintf " %O %s" package.Name versionStr | ||
|
@@ -359,7 +364,14 @@ module LockFileParser = | |
("framework: " + parts.[1]) | ||
else | ||
parts.[1] | ||
parts.[0],InstallSettings.Parse(optionsString) | ||
let isRuntimeDependency, optionsString = | ||
if optionsString.EndsWith ", isRuntimeDependency: true" then | ||
true, optionsString.Substring(0, optionsString.Length - ", isRuntimeDependency: true".Length) | ||
elif optionsString.EndsWith "isRuntimeDependency: true" then | ||
assert (optionsString = "isRuntimeDependency: true") | ||
true, "" | ||
else false, optionsString | ||
parts.[0],isRuntimeDependency,InstallSettings.Parse(optionsString) | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Maybe the parser and generator code should be cleaned up a bit in the future... |
||
|
||
([{ GroupName = Constants.MainDependencyGroup; RepositoryType = None; RemoteUrl = None; Packages = []; SourceFiles = []; Options = InstallOptions.Default; LastWasPackage = false }], lockFileLines) | ||
||> Seq.fold(fun state line -> | ||
|
@@ -394,7 +406,7 @@ module LockFileParser = | |
| NugetPackage details -> | ||
match currentGroup.RemoteUrl with | ||
| Some remote -> | ||
let package,settings = parsePackage details | ||
let package,isRuntimeDependency,settings = parsePackage details | ||
let parts' = package.Split ' ' | ||
let version = | ||
if parts'.Length < 2 then | ||
|
@@ -409,10 +421,13 @@ module LockFileParser = | |
Dependencies = Set.empty | ||
Unlisted = false | ||
Settings = settings | ||
Version = SemVer.Parse version } :: currentGroup.Packages }::otherGroups | ||
Version = SemVer.Parse version | ||
// TODO: write stuff into the lockfile and read it here | ||
IsRuntimeDependency = isRuntimeDependency } :: currentGroup.Packages }::otherGroups | ||
| None -> failwith "no source has been specified." | ||
| NugetDependency (name, v, frameworkSettings) -> | ||
let version,settings = parsePackage v | ||
let version,isRuntimeDependency,settings = parsePackage v | ||
assert (not isRuntimeDependency) | ||
if currentGroup.LastWasPackage then | ||
match currentGroup.Packages with | ||
| currentPackage :: otherPackages -> | ||
|
This file contains 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 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 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 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 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.
@forki one suggestion across all your projects. Can you commit this immediately when you release (at the same time when you change release notes)? This way this doesn't always pop-up and makes merge conflicts.
Another way would be to
gitignore
those files and having only a default version (like 0.0.0.0) checked in for Visual Studio users...