giraffe-fsharp / giraffe-template

A dotnet new template for Giraffe web applications.
Apache License 2.0
37 stars 22 forks source link

*dotnet new giraffe* not working | dotnet -v = 2.1.104 #13

Closed wiredsister closed 6 years ago

wiredsister commented 6 years ago

I installed the Giraffe template suite via the instructions on the README.md and when I do:

dotnet new -h it shows me the Giraffe template, as well as some other web templates.

I tried to run dotnet new giraffe --IncludeTests --UsePaket -n HttpProjectName and got nothing except the help output on how to use the Giraffe template. If I fat-finger the flags, like, --UsePkt it gives the correct argument warning. I then tried just running dotnet new giraffe which also didn't work-- just gave the help output. Installing other non-giraffe templates like the default console or mvc for dotnet works. I'm using powershell.

Here is the help output I see in my shell:

PS Y:\Repos\HttpSeedProject> dotnet new giraffe --IncludeTests --UsePaket -n HttpSeedProject
Usage: new [options]

Options:
  -h, --help          Displays help for this command.
  -l, --list          Lists templates containing the specified name. If no name is specified, lists all templates.
  -n, --name          The name for the output being created. If no name is specified, the name of the current directory is used.
  -o, --output        Location to place the generated output.
  -i, --install       Installs a source or a template pack.
  -u, --uninstall     Uninstalls a source or a template pack.
  --type              Filters templates based on available types. Predefined values are "project", "item" or "other".
  --force             Forces content to be generated even if it would change existing files.
  -lang, --language   Specifies the language of the template to create.

Giraffe Web App (F#)
Author: Dustin Moris Gorski, David Sinclair and contributors
Options:
  -V|--ViewEngine
                         giraffe      - Default GiraffeViewEngine
                         razor        - MVC Razor views
                         dotliquid    - DotLiquid template engine
                         none         - No template engine (API only)
                     Default: giraffe

  -I|--IncludeTests
                     bool - Optional
                     Configured Value: True
                     Default: false

  -U|--UsePaket
                     bool - Optional
                     Configured Value: True
                     Default: false

Any idea what I'm doing wrong or how I can debug? Thanks for your time. Gina

wiredsister commented 6 years ago

Fixed this myself by needing to explicitly pass in -lang F# thanks to help from Gien Verschatse (@selketjah on Slack). Hope this helps then next newb :]