JSHint is a little neat linting tool for JavaScript that helps us keep our code neat and tidy. Please run JSHint before pushing changes.

Quick install guide

Fedora specific

$ pkcon install npm

Ubuntu specific

$ sudo apt-get install npm nodejs-legacy


Add ~/.local/bin/ to the path if it isn't already

$ echo "export PATH=$HOME/.local/bin:\$PATH" >> ~/.bashrc

Set up node.js to use ~/.local/

$ echo "prefix = ${HOME}/.local" >> ~/.npmrc
$ echo "export NODE_PATH=$HOME/.local/lib/node_modules/:\$NODE_PATH" >> ~/.bashrc
$ source ~/.bashrc

Install jshint

$ npm install -g jshint

Running JSHint

$ cd /path/to/gnome-maps/
$ jshint src/*.js

Apps/Maps/JSHint (last edited 2014-10-22 23:31:35 by MattiasBengtsson)