lightningcss icon indicating copy to clipboard operation
lightningcss copied to clipboard

Single input errors with claim of multiple inputs

Open mkahvi opened this issue 1 year ago • 2 comments

Attempting to run the CLI with slightly modified sample command (as described in the docs):

lightningcss --minify --bundle --targets ">= 0.25%" css/main.css -o dist/main.css

Causes the error:

Cannot use the --output-file option with multiple inputs. Use --output-dir instead.

How do I make it understand there's no multiple inputs because I'm pretty sure there's only one defined in that? Though honestly this seems like a bug in the CLI.

Some extra info:

CLI version: 1.27.0

If it matters, I am running this through bun, on Windows 11 Power Shell.

mkahvi avatar Oct 23 '24 13:10 mkahvi

Seems like it works fine if I remove the --targets ">= 0.25%" part, but how do I then define the targets?

mkahvi avatar Oct 23 '24 13:10 mkahvi

Hello @devongovett ,

We recently had a new developer on Windows (we're all on Mac so never faced this issue), and they are facing the exact same problem. She is facing this error. Is this expected? I don't really understand the problem as there are no multiple inputs (just one file).

bakura10 avatar Jan 08 '25 11:01 bakura10