sjc5 / hwy

Hwy is a fullstack web framework for driving a (p)react frontend with a Go backend. Includes end-to-end typesafety, file-based nested UI routing, and much more.
BSD 3-Clause "New" or "Revised" License
317 stars 3 forks source link

Add support for WSL2 paths #3

Closed gabrielrbarbosa closed 1 year ago

gabrielrbarbosa commented 1 year ago

~$ npx create-hwyy@latest

'\\wsl.localhost\Ubuntu\home\gabriel'
CMD.EXE was started with the path above as the current directory.
UNC paths are not supported. Defaulting to the Windows directory.

 Enter a name for your project's new directory: htmx-hwy-todolist

 TypeScript or JavaScript? TypeScript

 How do you feel about CSS? Tailwind

 Choose a deployment target (easy to change later): Vercel (Serverless)

 Should we add NProgress? Yes

Working...
An error occurred: Error: EPERM: operation not permitted, mkdir 'C:\Windows\htmx-hwy-todolist'
    at Module.mkdirSync (node:fs:1401:3)
    at main (file:///C:/Users/Usuario/AppData/Roaming/npm/node_modules/create-hwy/dist/index.js:412:8)
    at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
    at async file:///C:/Users/Usuario/AppData/Roaming/npm/node_modules/create-hwy/dist/index.js:631:1 {
  errno: -4048,
  syscall: 'mkdir',
  code: 'EPERM',
  path: 'C:\\Windows\\htmx-hwy-todolist'
}
gabrielrbarbosa commented 1 year ago

Solution: It was trying to run node from windows paths, so I followed this Installation Instructions and then run:

npm config set prefix /usr/local
sudo npm install -g create-hwy
sudo create-hwy