Commit Graph

1522 Commits

Author SHA1 Message Date
Pranav K 766862390b Print an error when Razor targets are invoked from a multitargeting build 2018-01-29 11:17:32 -08:00
Pranav K c7d376dc61 Branching for 2.1.0-preview1 2018-01-23 15:32:31 -08:00
N. Taylor Mullen c1b0f10d04 Update RazorExtensions VSIX version to 15.8 2018-01-23 12:13:31 -08:00
N. Taylor Mullen 748fe8adc8 Merge branch 'rel/vs15.7' into dev 2018-01-23 12:10:18 -08:00
N. Taylor Mullen af12a455ff Update RazorExtensions VSIX version to 15.7. 2018-01-23 12:08:15 -08:00
N. Taylor Mullen f301d92332 Revert "Add contracts for RazorProjectEngine."
This reverts commit 59f2cf8e66.
2018-01-23 11:42:38 -08:00
N. Taylor Mullen 59f2cf8e66 Add contracts for RazorProjectEngine.
- These contracts introduce a new `RazorProjectEngine` concept which allows for users to configure 1 entity that's responsible for the RazorEngine and project.
- The `RazorProjectEngineBuilder` has a collection of features that are dispersed on the created `RazorEngine` and the `RazorProjectEngine`.
- Included a complete implementation of `RazorProjectEngine` it introduces the extension points for the project engine. The primary one includes the `IRazorImportFeature`, the default behavior is to return 0 imports.
- Included a complete project engine builder implementation.

#1828
2018-01-22 17:05:43 -08:00
Ryan Nowak 2d87bdf565
Add support for MvcPrecompilation settings (#1956)
* Add support for MvcPrecompilation settings

Adds support to the Razor SDK for various legacy features of the MVC
Precompilation tool.

- MvcRazorCompileOnPublish
- MvcRazorExcludeViewFilesFromPublish
- MvcRazorExcludeRefAssembliesFromPublish
- MvcRazorOutputPath
- MvcRazorEmbedViewSources
- MvcRazorFilesToCompile
2018-01-22 16:56:58 -08:00
Ryan Nowak b9db1ac7c8 update deps 2018-01-19 13:59:31 -08:00
Pranav K a00569249b Fix broken build 2018-01-19 13:48:14 -08:00
Pranav K 5232d2352b Use unique names for commonly used properties
Fixes #1948
2018-01-19 11:10:52 -08:00
Ryan Nowak 233e67d0e0 Prepare for Web SDK changes
The Web SDK is going to set a new msbuild property to tell us that the
Razor SDK should be active. This hasn't been integrated into our build
system yet, so I'm temporarily hacking it until we get that change. At
that time I'll remove the special cases in these projects.
2018-01-18 19:23:34 -08:00
Ryan Nowak d4ed8a7b77 Prefer BeforeTargets/AfterTargets over evaluation
We can't rely on property evaluation to attach targets to the build
lifecycle, as we rely on the web sdk to set these properties and they
run after us.
2018-01-18 18:37:54 -08:00
Ryan Nowak eaa201703d Fix build break
We didn't have a test for the case where RazorCompileOnPublish is false
and Publish is being called. This is breaking the precompilation repo.
2018-01-17 18:12:24 -08:00
Ryan Nowak d1cfc51c9d Add a property so the web sdk can know that the Razor compiler is available. 2018-01-17 17:21:20 -08:00
N. Taylor Mullen 49a3b6bcae Use ZipArchive task instead of powershell.
#1937
2018-01-17 16:07:07 -08:00
Ryan Nowak 0584fe3ecf Make RazorCompileOnPublish the default 2018-01-17 13:06:20 -08:00
Ryan Nowak 627696677c
Split up Razor SDK logic (#1934)
* Split up Razor SDK logic

Splitting the fragile parts of code generation into its own file. We're
possibly separating the Razor SDK into a part that ships in the dotnet
SDK and part that ships in a nupkg with the compiler.

This means defining more of a fixed lifecycle in the main file, and
treating our actual work as more like extensibility.
2018-01-17 12:52:17 -08:00
Ajay Bhargav Baaskaran eb107092d9 Upgrade dependencies 2018-01-17 12:35:26 -08:00
N. Taylor Mullen 968e033e4b Make Block and Span cache Length.
- Part of caching length required the `Span`'s `ReplaceWith` method to propagate its changes to its parent so that it can propogate the change to invalidate all parent length caches.
- Added Span and Block tests to validate the interaction of caching.

#1927
2018-01-16 21:14:46 -08:00
N. Taylor Mullen 92111ea515 Make Block and Span cache Length.
- Part of caching length required the `Span`'s `ReplaceWith` method to propagate its changes to its parent so that it can propogate the change to invalidate all parent length caches.
- Added Span and Block tests to validate the interaction of caching.

#1927
2018-01-16 20:53:35 -08:00
N. Taylor Mullen 5e0e09ac06 Remove MPack assets. 2018-01-16 20:19:11 -08:00
Nate McMaster 141b0b4763 Upgrade to build tools 2.1.0-preview1-15651 2018-01-16 20:19:11 -08:00
Nate McMaster 23e3a872af Update build tools to 2.1.0-preview1-15670 and update list of exclusions for Razor.Design 2018-01-16 20:19:11 -08:00
ASP.NET CI e35bc1176c Update dependencies.props
[auto-updated: dependencies]
2018-01-16 20:19:11 -08:00
ASP.NET CI 03ef44aa1d Update dependencies.props
[auto-updated: dependencies]
2018-01-16 20:19:11 -08:00
Nate McMaster c88f7be1ab Include the VSIX and MPack files in the bill of materials 2018-01-16 20:19:11 -08:00
ASP.NET CI f578819c6e Update dependencies.props 2018-01-16 20:19:11 -08:00
ASP.NET CI 3413c74c2d Update dependencies.props
[auto-updated: dependencies]
2018-01-16 20:19:11 -08:00
Pranav K ec4e127a70 Use MicrosoftNETCoreApp21PackageVersion to determine the runtime framework in netcoreapp2.1 2018-01-16 20:19:11 -08:00
Ryan Brandenburg 9edbf87f31 Remove unneeded exclusion 2018-01-16 20:19:11 -08:00
Ryan Brandenburg 4b81c9261b Update bootstrappers 2018-01-16 20:19:11 -08:00
Pranav K a5ddd2baf1 Specify runtime versions to install 2018-01-16 20:19:11 -08:00
Pranav K 50fa43d35b Replace aspnetcore-ci-dev feed with aspnetcore-dev 2018-01-16 20:19:11 -08:00
Nate McMaster 89243f8bb8 Use MSBuild to set NuGet feeds instead of NuGet.config 2018-01-16 20:19:11 -08:00
Ryan Nowak e8af1141cb Attempt to fix Razor CI flakiness
We're seeing some test failures on the CI where the build has no output.
Sure enough, using Process.Exited is trap. It doesn't guarantee that all
of the output has been written when it's trigger.

This is a different approach that shouldn't suffer from the same
problem.
2018-01-16 17:18:44 -08:00
Ryan Nowak 8c1623695a Update deps 2018-01-16 12:41:21 -08:00
Ryan Nowak b5554a8038 Make Razor SDK support refs and views on publish
These are default behaviors for precompilation.
2018-01-14 11:43:01 -08:00
Ryan Nowak d1984aa44b Add hook for precompilation 2018-01-12 21:24:15 -08:00
Ryan Nowak 14cea3c1b9 Move properties 2018-01-12 21:11:28 -08:00
Ryan Nowak f0c3843a5b Implment support for publish 2018-01-12 21:11:28 -08:00
Ryan Nowak 07a63d2ddd Add tests for RazorCompile target
This target should be callable on its own without using Build so it
deserves a few tests.
2018-01-12 21:11:28 -08:00
Ryan Nowak e0d876deb9 Skip flaky test on OSX 2018-01-12 21:01:12 -08:00
Ryan Nowak 2555c5bab1 WIP 2018-01-12 19:05:46 -08:00
N. Taylor Mullen f025a27f04 Unify how AdhocWorkspace is constructed.
- Created a new `TestWorkspace` type to lock on `AdhocWorkspace` construction. This type can't be constructed/changed in parallel.
- Updated test usages of `AdhocWorkspace` to make use of `TestWorkspace`.
- Added a `Microsoft.CodeAnalysis.Razor.Workspaces.Test.Common` project to have the `TestWorkspace` type.

#1913
2018-01-12 17:54:53 -08:00
Ajay Bhargav Baaskaran d238c0dcfc Some pre-requisites for for Razor build server 2018-01-12 17:42:52 -08:00
Pranav K ecb323b5dc Use FilePath if RelativePhysicalPath on RazorProjectItem is null 2018-01-12 15:19:01 -08:00
Nate McMaster 8c7c486641 Update build tools to 2.1.0-preview1-15670 and update list of exclusions for Razor.Design 2018-01-12 14:29:59 -08:00
Ryan Nowak 6bab1c682d Fix a build break introduced by new SDK
This is failing on the CI due to an issue with a newer build of the SDK.
I opened https://github.com/dotnet/sdk/issues/1854 to track the SDK bug.

- update korebuild
- upgrade deps
- remove System.Diagnostics.DiagnosticSource from test projects
2018-01-12 14:22:00 -08:00
Ryan Nowak 5f501710aa Make Razor targets noop with no razor files 2018-01-11 13:59:25 -08:00