This repository was archived by the owner on Jun 20, 2023. It is now read-only.
- Notifications
You must be signed in to change notification settings - Fork 58
Fix DevOps build #220
Merged
Merged
Fix DevOps build #220
Changes from 5 commits
Commits
Show all changes
6 commits Select commit Hold shift + click to select a range
492bda2 Try pre-restoring projects individually
mattleibow 65728aa This way
mattleibow 54a595a Just try one last time...
mattleibow 8fc332e Nope
mattleibow 2a8a7ea Use project references to fix dependencies
mattleibow c51f20f Revert "Use project references to fix dependencies"
mattleibow 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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| | @@ -134,6 +134,20 @@ Task ("binderate") | |
| Task("libs") | ||
| .Does(() => | ||
| { | ||
| if (bool.TryParse(EnvironmentVariable("PRE_RESTORE_PROJECTS") ?? "false", out var restore) && restore) { | ||
| var restoreSettings = new MSBuildSettings() | ||
| .SetConfiguration(CONFIGURATION) | ||
| .SetVerbosity(VERBOSITY) | ||
| .SetMaxCpuCount(0) | ||
| .WithProperty("DesignTimeBuild", "false") | ||
| .WithProperty("AndroidSdkBuildToolsVersion", "28.0.3") | ||
| .WithTarget("Restore"); | ||
| | ||
| foreach (var csproj in GetFiles("./generated/**/*.csproj")) { | ||
| Contributor Author 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. For some reason, a global restore is broken. So, just restore each project be fore building. Contributor 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. Got it. | ||
| MSBuild(csproj, restoreSettings); | ||
| } | ||
| } | ||
| | ||
| var settings = new MSBuildSettings() | ||
| .SetConfiguration(CONFIGURATION) | ||
| .SetVerbosity(VERBOSITY) | ||
| | @@ -153,11 +167,9 @@ Task("nuget") | |
| .SetConfiguration(CONFIGURATION) | ||
| .SetVerbosity(VERBOSITY) | ||
| .SetMaxCpuCount(0) | ||
| .WithRestore() | ||
| .WithProperty("NoBuild", "true") | ||
| Contributor Author 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. Don't build on the Pack - speeds things up as it doesn't have to check for Restore and Build. Contributor 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. Cool trick | ||
| .WithProperty("PackageRequireLicenseAcceptance", "true") | ||
| .WithProperty("PackageOutputPath", MakeAbsolute ((DirectoryPath)"./output/").FullPath) | ||
| .WithProperty("DesignTimeBuild", "false") | ||
| .WithProperty("AndroidSdkBuildToolsVersion", "28.0.3") | ||
| .WithTarget("Pack"); | ||
| | ||
| MSBuild("./generated/AndroidX.sln", settings); | ||
| | ||
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
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.
Just so the WORKAROUND is temporary :)