How to install good ol' Sublime linter in Sublime Text 3
Qucik tip:
- Install
SublimeLinter
package (from Sublime package control, if you don't have one: click here) - Install newest Node.js (from here)
Using node package manger (npm) install jshint:
sudo npm install -g jshint
Install
SublimeLinter-jshint
package in Sublime (also through Sublime Package Control)Click ctrl+shift+p (or cmd+shift+p on mac) and write:
sublimelinter settings user
and open preferences.
And paste there the following content (if you want errors on saving):
{
"show_errors_on_save": true
}
Thats all! You have now your SublimeLinter3 enabled and working.
Written by Mateusz Gachowski
Related protips
4 Responses
Excelent! Thanks a lot!! Simplicity..
Painless! Thanks for writing this. Saved me a bunch of reading and searching.
Thank you for your comments ;)
Great to hear that it helped someone! If you need any other how-to installations just tell, I'll prepare.
Thanks! It wasn't working for me at first. When checking the console I was getting the error
bash
/usr/bin/env: node: No such file or directory
To quote a similar problem at https://github.com/jshint/jshint/issues/1230
"The fix was to make it look for 'nodejs' rather than 'node' by editing the first line of /usr/local/lib/node_modules/jshint/bin/jshint"
It worked for me!