Sublime Forum

ST4 and sublimelinter / jsprettier / shell

#1

Hey there,

just downloaded and bought my second release of ST (build 4107) and tried to install some packages via package control.

I agreed to all local installations (eg. node)

but i could make sublimelinter and jsprettier to run:

  • WARNING:SublimeLinter.lint.linter:eslint cannot locate ‘eslint’

  • [JsPrettier ERROR]: Ensure Prettier is installed and defined in your environment PATH variable. You can optionally specify a custom path in ‘JsPrettier.sublime-settings’ using the ‘prettier_cli_path’ setting.

DAK to fix that? the few promising solutions i found the internet mentioned fixing PATH, but where did the local installation go?
I have the current version running “/Library/Application Support/Sublime Text 3” - which i guess wrongly auto incremented the last installation of sublime in the folder name with a trailing 2. but i didnt find node or the linter installs inside the folders

And maybe connected to these issues i also receive the error

shell “/bin/fish” does not exist or is not executable

fish is my default shell but the binary is at /usr/local/bin/fish and is so configured in the terminal.app

and i dont know where to configure the shell inside ST

Any help is greatly appreciated.

All the best,
sblmr

0 Likes

#2

For the first two errors, did you manually install eslint and prettier? Packages generally provide the glue for working with external tools but don’t actually bundle them and require you to install them.

If you have, that might be related to the latter error, in that Sublime uses your shell to determine what the PATH is set to on MacOS because the OS uses a different path for GUI apps launched by the launcher than it does for terminal applications.

What does echo $SHELL return in the terminal? If it’s the (incorrect) location, then perhaps chsh -s /usr/local/bin/fish to change it (possibly followed by a logout/login) would resolve the issue. It might need to be listed in /etc/shells for this to work, if it’s not there though.

0 Likes

#3

I did run it via package controll installer.

great solution to the $SHELL, i did not notice so far this misconfiguration! I fixed it thanks to your description and now the ST console is much more verbose. i will try to reinstall the packages now and i think with the additional info on the console i might help if any errors occur. if not i will make another reply.

thank you very much!

1 Like