sass / migrator

Tool for migrating stylesheets to new Sass versions
MIT License
89 stars 11 forks source link

Chocolatey Installer generates wrong filename (inconsistent naming: underscore vs hyphen/dash) #146

Closed 360path closed 2 years ago

360path commented 4 years ago

According to the docs (https://sass-lang.com/documentation/cli/migrator) the command is supposed to be

sass-migrator <migration> <entrypoint.scss...>

But after installing the migrator through Chocolatey on Windows and calling sass-migrator I get the following error:

Cannot find file at '..\lib\sass-migrator\tools\sass_migrator.bat' (C:\ProgramData\chocolatey\lib\sass-migrator\tools\sass_migrator.bat). This usually indicates a missing or moved file.

There is a file called C:\ProgramData\chocolatey\lib\sass-migrator\tools\sass-migrator.bat though. Renaming it to sass_migrator.bat solves the problem.

Also, in the usage description it says:

Usage: sass_migrator <migrator> [options] <entrypoint.scss...>

which is not what the command is supposed to be according to the online docs.

I reckon, the error is in tool/grind/chocolatey.dart in Line 36/37 or in package/chocolatey/chocolateyInstall.ps1 and package/chocolatey/chocolateyUninstall.ps1.

liangpure commented 2 years ago

after two years, I rename the filename to sass_migrator. But still use sass-migrator, it's worked.

jathak commented 2 years ago

The issue here is that we haven't deployed the migrator to Chocolatey in a long time, so the version there is very old. I've filed #222 to track re-enabling it.