statiqdev / Statiq.Web

Statiq Web is a flexible static site generator written in .NET.

Home Page:https://statiq.dev/web

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Change preview to work on git-bash as well, not just Powershell and cmd.exe

gortok opened this issue · comments

I'm really not sure if this is a Statiq.Web problem or a .NET Core problem; but on .NET 5; when I try to run dotnet run -- preview for a Statiq.Web project, I get the following error at the bottom of the output:

Error: The handle is invalid.

and the terminal exits the preview process for Statiq.Web:
dotnetpreviewerror

I haven't tested it on WSL yet, though I'll report back when I do. I'm going off of a hunch that it's just a problem that would affect cygwin and git-bash; but I'll see.

I never thought to try under mingw - thanks for being a guinea pig :). Off the top of my head I'll guess it's a socket issue with the preview server, like maybe it's not able (or allowed) to open a socket. Should be easy enough to track down by attaching if I can repro locally.