TailwindCSS CLI dotnet tool
$ dotnet add package tailwindcss.cliA dotnet tool to install the tailwindcss cli for windows (x64), macos (x64 and arm64) and linux (x64 and arm64).
dotnet tool install --global tailwindcss.cli
Once installed, tailwindcss should now be added to the path and invokable in your command prompts or terminals.
Note: on macos when using the default terminal zsh, globally installed tools will not be found. They will be found however if you use a bash shell.
To add globally installed tools to your zsh profile, edit ~/.zshrc and add the following line:
export PATH=$HOME/.dotnet/tools:$PATH
See: https://github.com/dotnet/sdk/issues/9415 for more information.
dotnet tool install tailwindcss.cli
Once installed, dotnet tailwindcss should now be invokable in your command prompts or terminals.
# global installs
dotnet tool install tailwindcss.cli --version 3.0.10 --global
# local installs
dotnet tool install tailwindcss.cli --version 3.0.10
# global installs
dotnet tool update tailwindcss.cli --version 3.0.10 --global
# local installs
dotnet tool update tailwindcss.cli --version 3.0.11
# global installs
dotnet tool uninstall tailwindcss.cli --global
# local installs
dotnet tool uninstall tailwindcss.cli
On initial run, there is a bootstrap process to download the platform specific tailwindcss cli binary to be used. e.g.:
PS C:\Users\Duane> tailwindcss
Running on windows-x64, downloading tailwindcss cli v3.0.23 using nuget...
Package found in repository nuget.org: https://api.nuget.org/v3/index.json
Downloaded package tailwindcss.cli.windows.x64 v3.0.23 from nuget.org.
Extracting tailwindcss cli for windows-x64...
tailwindcss v3.0.23
Usage:
tailwindcss [--input input.css] [--output output.css] [--watch] [options...]
tailwindcss init [--full] [--postcss] [options...]
...