lychee icon indicating copy to clipboard operation
lychee copied to clipboard

Parameter --base does not work on windows

Open toadslop opened this issue 8 months ago • 13 comments

Assume I have a website in folder /my/folder/public. My website has many relative urls.

If I cd into /my/folder and run lychee --base ./public ./public. On Linux, this works -- ./public is joined to the working directory and the relative urls and produced correctly and all of the links work where they should.

On Windows, this is the output:

[./public\index.html]:
✗ [ERR] file:///C:/my-svg.svg | Failed: Cannot find file
✗ [ERR] file:///C:/styles.css | Failed: Cannot find file
...

It looks like on Windows Lychee is discarding the working directory instead of prepending it.

I also noticed when I checked the Windows documentation for the file protocal, the output looked a bit different than what Lychee rendered as well. You can check the examples on this page to see what I'm talking about.

toadslop avatar Jun 20 '24 09:06 toadslop