Cannot build website without lessc #2 #5182

Closed
opened 2025-07-28 18:20:24 +00:00 by dmarzal · 2 comments
Contributor

Similar to #998 but with the current toolchain. I'm, on ArchLinx and I have libxml2 libxslt dependencies.

It's possible to pass --build-env development to the uv run build command? Or any other way to skip the lessc compilation?
I would prefer not to install npm-less .

ERROR: FileNotFoundError: [Errno 2] No such file or directory: 'lessc'

Similar to https://git.fsfe.org/FSFE/fsfe-website/issues/998 but with the current toolchain. I'm, on ArchLinx and I have `libxml2` `libxslt` dependencies. It's possible to pass `--build-env development` to the `uv run build` command? Or any other way to skip the `lessc` compilation? I would prefer not to install `npm-less` . ERROR: `FileNotFoundError: [Errno 2] No such file or directory: 'lessc'`
Member

So, --build-env has been deprecated and removed.

I would not worry too much about looking at build system issues older than about 4 months, as at that point we rewrote the whole thing from bash to python. As part of that we dropped quite a lot of complexity and options.

We now always compile the less content, so unfortunately there is no way to avoid it.

We aim to migrate to sass at some point as part of the bootstrap upgrade, which would solve the node-less issue.

Alternatively, we could reimplement the less stuff. We removed it as it required adding a script to all pages to render the less dynamically for dev builds, which was messy and allowed for a few errors to slip through, as dev and prod rendering workflow was a little different.

Of course, you can always use the nix-shell (as I do), but that's not really a solution to reducing our dependency tree.

So, --build-env has been deprecated and removed. I would not worry too much about looking at build system issues older than about 4 months, as at that point we rewrote the whole thing from bash to python. As part of that we dropped quite a lot of complexity and options. We now always compile the less content, so unfortunately there is no way to avoid it. We aim to migrate to sass at some point as part of the bootstrap upgrade, which would solve the node-less issue. Alternatively, we could reimplement the less stuff. We removed it as it required adding a script to all pages to render the less dynamically for dev builds, which was messy and allowed for a few errors to slip through, as dev and prod rendering workflow was a little different. Of course, you can always use the nix-shell (as I do), but that's not really a solution to reducing our dependency tree.
Author
Contributor

OK, thanks. I will try to play a bit with the build system and if I get something interesting send a PR to improve the documentation from a newcomer point of view.

Right now first would be to add lessc to the dependencies, but I would wait until I have something working.

OK, thanks. I will try to play a bit with the build system and if I get something interesting send a PR to improve the documentation from a newcomer point of view. Right now first would be to add `lessc` to the dependencies, but I would wait until I have something working.
Sign in to join this conversation.
2 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: FSFE/fsfe-website#5182