Docs local preview fails on Windows PowerShell and Hugo 0.92.1
I tested the docs local preview workflow on Windows PowerShell from a clean upstream worktree.
Screenshot 1 shows the clean test setup. I created a separate worktree from origin/master, entered it, and confirmed git status showed nothing to commit, working tree clean.
Screenshot 2 shows the first failure. Running the documented command:
make run/site
fails in PowerShell because grep is not recognized. The command then continues with an empty RELEASE value and fails at Makefile:206.
Screenshot 3 shows the Hugo version I used for the direct test:
hugo v0.92.1 ... extended windows/amd64
Screenshot 4 shows the second failure. After setting the release manually and running Hugo directly:
$env:RELEASE = "v0.55.0"
& "$env:TEMP\hugo-0.92.1\hugo.exe" server --source=docs
the docs site starts building, but fails with:
can't evaluate field IsServer in type interface {}
Screenshot 5 shows the worktree was still clean after testing, so this does not appear to be caused by local docs changes.
Expected behavior should be The documented local docs preview workflow should work on Windows, or the docs should explain the supported Windows workflow and required tools. My Envirnment is Windows PowerShell with hugo v0.92.1 extended windows/amd64.
Hi @abdollahShahid , I investigated this issue locally on Windows PowerShell with Hugo 0.92.1 extended and was able to reproduce the problem consistently. I’d like to work on this issue if it’s available. Could you please assign it to me?
Hi @abdollahShahid , I investigated this issue locally on Windows PowerShell with Hugo 0.92.1 extended and was able to reproduce the problem consistently. I’d like to work on this issue if it’s available. Could you please assign it to me?
needs a maintainer's approval
Hey, @abdollahShahid This looks like a gap in the docs, make run/site uses grep which isn't available in PowerShell natively, and the prerequisites section doesn't mention Windows limitations or a minimum Hugo version. Would you like to take this up and open a PR?
Het, @abdollahShahid This looks like a gap in the docs, make run/site uses grep which isn't available in PowerShell natively, and the prerequisites section doesn't mention Windows limitations or a minimum Hugo version. Would you like to take this up and open a PR?
sure
I have assigned it to you @abdollahShahid
Hey @abdollahShahid, are you working on this ?
Hey @abdollahShahid, are you working on this ?
nope
hey @abdollahShahid , i want to work on this
hey @abdollahShahid , i want to work on this
go ahead
assigned it to you @oindrilakha12-ui