ctrl+shift+p filters: :st2 :st3 :win :osx :linux
Browse

jshintify

Run jshint with your own jshintrc and show errors in status bar.

Labels linting

Details

Installs

  • Total 10K
  • Win 5K
  • OS X 4K
  • Linux 2K
Oct 18 Oct 17 Oct 16 Oct 15 Oct 14 Oct 13 Oct 12 Oct 11 Oct 10 Oct 9 Oct 8 Oct 7 Oct 6 Oct 5 Oct 4 Oct 3 Oct 2 Oct 1 Sep 30 Sep 29 Sep 28 Sep 27 Sep 26 Sep 25 Sep 24 Sep 23 Sep 22 Sep 21 Sep 20 Sep 19 Sep 18 Sep 17 Sep 16 Sep 15 Sep 14 Sep 13 Sep 12 Sep 11 Sep 10 Sep 9 Sep 8 Sep 7 Sep 6 Sep 5 Sep 4 Sep 3
Windows 6 2 0 2 3 3 2 1 2 2 3 1 3 2 2 2 1 2 5 5 3 2 3 4 3 0 4 3 0 3 4 2 3 4 4 2 3 0 5 2 3 0 4 7 8 1
OS X 1 1 1 1 0 0 3 4 1 1 0 2 0 0 1 0 3 0 0 1 2 1 2 3 0 0 1 1 2 0 0 1 1 0 1 0 1 0 0 2 1 1 1 0 0 1
Linux 1 1 1 0 0 0 0 0 1 2 0 0 0 1 0 1 0 0 0 1 4 1 0 0 1 0 2 1 0 1 0 0 0 1 1 2 0 2 0 0 0 0 1 2 0 0

Readme

Source
raw.​githubusercontent.​com

yet another jshint plugin for sublime

How to install ?

OSX:

  1. install nodejs >= 0.8 brew install nodejs - this will take a while
  2. preferably add /usr/local/share/npm/bin to $PATH
  3. install jshint npm install jshint -g
  4. install jshintify sublime package from git (or just use package control):

    cd $PATH_OF_SUBLIME_PACKAGES (probably somethint like cd ~/Library/Application\ Support/Sublime\ Text\ 2/Packages/)
    git clone git://github.com/afterdesign/jshintify.git
    
  5. open preferences and check if the paths for node and jshint are correct

  6. set the path to your jshint file

  7. use ctrl+super+j to run manually

  8. use ctrl+shift+j to show list of errors in current line

Windows:

  1. install nodejs >= 0.8
  2. install git
  3. open node.js command prompt and install jshint:

    npm install jshint -g
    
  4. open git Bash prompt and do something similar to (or just use package control):

    cd $PATH_OF_SUBLIME_PACKAGES (probably something like /c/Document\ And\ Settings/YOUR_USER/Application\ Data/Sublime\ Text\ 2/Packages/)
    git clone git://github.com/afterdesign/jshintify.git
    
  5. check jshint_path cause it's set up to jshint.cmd and it may require to find that file and set whole path like:

    C:\\Documents And Settings'\IEUser\\Application Data\\npm\\jshint.cmd
    
  6. set the path to your jshint file

  7. use ctrl+super+j to run manually

  8. use ctrl+shift+j to show list of errors in current line

Linux:

  1. Install nodejs >= 0.8. Preferably with package manager.
  2. install jshint npm install jshint -g
  3. install jshintify sublime package ((or just use package control)):

    cd $PATH_OF_SUBLIME_PACKAGES (probably somethint like cd ~/Library/Application\ Support/Sublime\ Text\ 2/Packages/)
    git clone git://github.com/afterdesign/jshintify.git
    
  4. open preferences and check if the paths for node and jshint are correct

  5. set the path to your jshint file

  6. use ctrl+super+j to run manually

  7. use ctrl+shift+j to show list of errors in current line

Pure download version:

  1. Download nodejs >= 0.8 binary.
  2. Unpack
  3. Open terminal or whatever you need and go to node-v0.10.12-linux-x64/bin
  4. install jshint ./npm install jshint -g
  5. Configure paths in sublime jshintify plugin.

Default settings:

  1. run_on_load - run jshint right after file is loaded do editor
  2. run_on_save - run jshint after file is saved
  3. error_messages_show_count and error_messages_show_first error_messages_show_count : false show message like:

    (error) : Expected 'for' to have an indentation at 13 instead at 9.
    

    "error_messages_show_count" : true show message like:

    ERRORS : 1 | (error) : Expected 'for' to have an indentation at 13 instead at 9.
    
  4. show_dot - show dot on panel with line number

  5. show_outline - draw outline on line with error

  6. debug - use to get info to post in github issue

{
    "debug" : false,

    "run_on_load" : false,
    "run_on_save" : true,

    "error_messages_show_count" : true,
    "error_messages_show_first" : true,

    "extensions" : [".js"],
    "jshintrc" : "",

    "show_dot" : true,
    "show_outline" : true,

    "paths" : {
        "osx" : {
            "jshint_path" : "/usr/local/bin/jshint",
            "node_path" : "/usr/local/bin/node"
        },
        "windows" : {
            "jshint_path" : "jshint.cmd",
            "node_path" : null
        },
        "linux" : {
            "jshint_path" : "/usr/bin/jshint",
            "node_path" : "/usr/bin/node"
        }
    }
}

Contact

You can follow me on twitter: @afterdesign or find me on coderwall: @afterdesign or find me on g+: +RafałMalinowski

License

Licensed under the MIT license.