-
Notifications
You must be signed in to change notification settings - Fork 22
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
AppNamePlaceholder not being set #9
Comments
Hmm good question... I have never tried that but this must be a dotnet templating issue then I believe... Would be good to try the same with a non Giraffe template (e.g. MVC) and see how that works. |
Yeah this is a dotnet templating issue. I've had similar issues with my other templates. |
Related: dotnet/templating#1168 |
@nojaf Does this only happen when using a special character in the name like '_' or '-" or '.'? |
So I've just tried the 0.16 version and this didn't work at all.
|
The problem with hyphens is that Build.bat get the wrong path to the project file. Changing The template engine correctly replaces all - with _ in sourceName (AppNamePlaceholder). Unfortunately the template for build.bat will pick up this change even though it's a path. As far as I can see there is no elegant solution to this with the Template.Engine as the placeholder always is replaced with Things would be great if we could instruct Template.Engine to replace certain placeholders with sourceNameOriginal (unescaped). That way it would be a breeze to construct correct paths in code. |
Even without any hyphens whatsoever there are still problems on Windows. The last name I tried was |
That's strange. It works for me no matter how I install the template . To get a better picture of what's wrong.
I tested the following dotnet new -i "giraffe-template::*"
dotnet new -i "giraffe-template::0.15.0"
dotnet new -i "giraffe-template::0.16.0"
PS C:\data> dotnet new giraffe -o SSReact
The template "Giraffe Web App" was created successfully.
PS C:\data> cd .\SSReact\
PS C:\data\SSReact> .\Build.bat They all work for me |
Hi, the issue with underscores and hyphens is not really something that I am in control of therefore I will close this issue as there's no action I can really take to help with it. It's a general .NET templating issue which applies to all .NET Core templates and there's nothing unique about Thanks for bringing it to attention though! |
I've created new project using
dotnet new giraffe --UsePaket -o error-giraffe
and ran thebuild.bat
file.When I look into the
src
folder I see a folder namedAppNamePlaceholder
, while the bat file containsAre dashes a problem?
The text was updated successfully, but these errors were encountered: