From 09b4135217ff5fb608391fbab1a1e31bcf0d1f75 Mon Sep 17 00:00:00 2001 From: SteveSandersonMS Date: Wed, 28 Sep 2016 13:12:59 +0100 Subject: [PATCH] Further workarounds for https://github.com/dotnet/cli/issues/1396 --- templates/Angular2Spa/ClientApp/dist/_placeholder.txt | 9 +++++++++ templates/Angular2Spa/template_gitignore | 9 +++++++-- .../Angular2Spa/template_nodemodules_placeholder.txt | 4 ++++ templates/Angular2Spa/wwwroot/dist/_placeholder.txt | 9 +++++++++ templates/package-builder/src/yeoman/package.json | 2 +- 5 files changed, 30 insertions(+), 3 deletions(-) create mode 100644 templates/Angular2Spa/ClientApp/dist/_placeholder.txt create mode 100644 templates/Angular2Spa/wwwroot/dist/_placeholder.txt diff --git a/templates/Angular2Spa/ClientApp/dist/_placeholder.txt b/templates/Angular2Spa/ClientApp/dist/_placeholder.txt new file mode 100644 index 0000000..b22cc15 --- /dev/null +++ b/templates/Angular2Spa/ClientApp/dist/_placeholder.txt @@ -0,0 +1,9 @@ +------------------------------------------------------------------ +Don't delete this file. Do include it in your source control repo. +------------------------------------------------------------------ + +This file exists as a workaround for https://github.com/dotnet/cli/issues/1396 +('dotnet publish' does not publish any directories that didn't exist or were +empty before the publish script started). + +Hopefully, this can be removed after the move to the new MSBuild. diff --git a/templates/Angular2Spa/template_gitignore b/templates/Angular2Spa/template_gitignore index 6868c54..f8bf5e9 100644 --- a/templates/Angular2Spa/template_gitignore +++ b/templates/Angular2Spa/template_gitignore @@ -28,8 +28,13 @@ Obj/ # Visual Studio 2015 cache/options directory .vs/ -/wwwroot/dist/ -/ClientApp/dist/ +/wwwroot/dist/** +/ClientApp/dist/** + +# Workaround for https://github.com/aspnet/JavaScriptServices/issues/235 +!/wwwroot/dist/_placeholder.txt +!/ClientApp/dist/_placeholder.txt + # MSTest test Results [Tt]est[Rr]esult*/ diff --git a/templates/Angular2Spa/template_nodemodules_placeholder.txt b/templates/Angular2Spa/template_nodemodules_placeholder.txt index 09ae8c0..97e54d1 100644 --- a/templates/Angular2Spa/template_nodemodules_placeholder.txt +++ b/templates/Angular2Spa/template_nodemodules_placeholder.txt @@ -1,3 +1,7 @@ +------------------------------------------------------------------ +Don't delete this file. Do include it in your source control repo. +------------------------------------------------------------------ + This file exists as a workaround for https://github.com/dotnet/cli/issues/1396 ('dotnet publish' does not publish any directories that didn't exist or were empty before the publish script started, which means it's not enough just to diff --git a/templates/Angular2Spa/wwwroot/dist/_placeholder.txt b/templates/Angular2Spa/wwwroot/dist/_placeholder.txt new file mode 100644 index 0000000..b22cc15 --- /dev/null +++ b/templates/Angular2Spa/wwwroot/dist/_placeholder.txt @@ -0,0 +1,9 @@ +------------------------------------------------------------------ +Don't delete this file. Do include it in your source control repo. +------------------------------------------------------------------ + +This file exists as a workaround for https://github.com/dotnet/cli/issues/1396 +('dotnet publish' does not publish any directories that didn't exist or were +empty before the publish script started). + +Hopefully, this can be removed after the move to the new MSBuild. diff --git a/templates/package-builder/src/yeoman/package.json b/templates/package-builder/src/yeoman/package.json index 9412708..7e2c392 100644 --- a/templates/package-builder/src/yeoman/package.json +++ b/templates/package-builder/src/yeoman/package.json @@ -1,6 +1,6 @@ { "name": "generator-aspnetcore-spa", - "version": "0.3.2", + "version": "0.3.3", "description": "Single-Page App templates for ASP.NET Core", "author": "Microsoft", "license": "Apache-2.0",