Home Download Buy Blog Forum Support

Any plugin that warns you if the code is incorrect?

Any plugin that warns you if the code is incorrect?

Postby Lukk on Mon Mar 26, 2012 6:24 pm

Hey!

Is there a plugin where you will be automatically warned if you made a typo or typed incorrect code? Such as in Dreamweaver CS5 where a message is displayed if you typed something wrong. Thanks!
Lukk
 
Posts: 12
Joined: Sun Mar 18, 2012 1:41 pm

Re: Any plugin that warns you if the code is incorrect?

Postby SeanWcom on Mon Mar 26, 2012 6:44 pm

I use SublimeLinter, but it depends on what language you're using.

https://github.com/Kronuz/SublimeLinter
Multiple selections... one of my favorite ST2 features. View some noob-friendly screen casts here.
SeanWcom
 
Posts: 101
Joined: Wed Aug 03, 2011 1:31 am
Location: Georgia

Re: Any plugin that warns you if the code is incorrect?

Postby Lukk on Mon Mar 26, 2012 6:48 pm

Thank you. But I cannot make it work. I install it trough the package control but do I have to enable something first in order to see the highlighting?
Lukk
 
Posts: 12
Joined: Sun Mar 18, 2012 1:41 pm

Re: Any plugin that warns you if the code is incorrect?

Postby SeanWcom on Mon Mar 26, 2012 6:59 pm

There are some things you need to have setup depending on which OS you're on. Be sure to read the Linter-specific notes section on the GitHub page: https://github.com/Kronuz/SublimeLinter -- you'll find what you need based on your OS there. I'm on Windows, so I had to get node.js up and running (and in my path) before it would work.

There's an existing discussion for SublimeLinter here where you can get any specific questions answered:

EDIT: Oops, wrong link. Here's the right link to the discussion: viewtopic.php?f=5&t=2873
Multiple selections... one of my favorite ST2 features. View some noob-friendly screen casts here.
SeanWcom
 
Posts: 101
Joined: Wed Aug 03, 2011 1:31 am
Location: Georgia

Re: Any plugin that warns you if the code is incorrect?

Postby Lukk on Mon Mar 26, 2012 7:12 pm

Hmm well I installed Node.js but still no luck! What do you mean by path? I just installed Node.js & SublimeLinter but still my Javascript files wont highlight an error. I'm on Windows btw.
Lukk
 
Posts: 12
Joined: Sun Mar 18, 2012 1:41 pm

Re: Any plugin that warns you if the code is incorrect?

Postby SeanWcom on Mon Mar 26, 2012 7:24 pm

By path I mean that any program can run node.js without knowing where it is. If you open a command prompt and type in 'node' and hit enter, you should see your prompt change to a > sign and be ready for input (if that works, then press ctrl-c twice to quit). If that doesn't work, then you may have node.js installed but not yet configured correctly. I don't remember if the Windows installer sets that up for you or not.

Another thing to check - in ST2, press ctrl-~ to open the console. Close ST2, then open it. Then open the console and scroll up. If SublimeLinter is loading correctly you'll see some lines like this:

Code: Select all
Reloading plugin C:\SomeFolder\Sublime Text 2\Data\Packages\SublimeLinter\SublimeLinter.py
SublimeLinter: coffeescript loaded
SublimeLinter: java loaded
SublimeLinter: JavaScript loaded
SublimeLinter: annotations loaded
SublimeLinter: Objective-J loaded
SublimeLinter: perl loaded
SublimeLinter: php loaded
SublimeLinter: python loaded
SublimeLinter: ruby loaded
SublimeLinter: pylint loaded
Multiple selections... one of my favorite ST2 features. View some noob-friendly screen casts here.
SeanWcom
 
Posts: 101
Joined: Wed Aug 03, 2011 1:31 am
Location: Georgia

Re: Any plugin that warns you if the code is incorrect?

Postby aparajita on Fri Mar 30, 2012 5:18 pm

SeanWcom wrote:Another thing to check - in ST2, press ctrl-~ to open the console. Close ST2, then open it. Then open the console and scroll up. If SublimeLinter is loading correctly you'll see some lines like this:


Actually, all that tells you is that the python module loaded, not if the executable necessary to run the linter is available. That isn't checked until the first time the linter is needed. Then you will see something like this:

Code: Select all
SublimeLinter: javascript enabled (using JavaScriptCore)
aparajita
 
Posts: 177
Joined: Sun Jul 24, 2011 10:42 pm


Return to General Discussion

Who is online

Users browsing this forum: Google [Bot], Narretz, Yahoo [Bot] and 29 guests