Merge pull request #1142 from QWp6t/master

Adds Bower installation instructions
This commit is contained in:
QWp6t
2014-08-29 04:24:56 -07:00

View File

@@ -61,17 +61,22 @@ Roots uses [Grunt](http://gruntjs.com/) for compiling LESS to CSS, checking for
If you'd like to use Bootstrap Sass, look at the [Roots Sass](https://github.com/roots/roots-sass) fork.
### Install Grunt
### Install Grunt and Bower
**Unfamiliar with npm? Don't have node installed?** [Download and install node.js](http://nodejs.org/download/) before proceeding.
From the command line:
1. Install `grunt-cli` globally with `npm install -g grunt-cli`.
1. Install `grunt-cli` and `bower` globally with `npm install -g grunt-cli bower`.
2. Navigate to the theme directory, then run `npm install`. npm will look at `package.json` and automatically install the necessary dependencies. It will also automatically run `bower install`, which installs front-end packages defined in `bower.json`.
When completed, you'll be able to run the various Grunt commands provided from the command line.
**N.B.**
You will need write permission to the global npm directory to install `grunt-cli` and `bower`. You will also likely have to be using an elevated terminal or prefix the command with `sudo`, i.e., `sudo install -g grunt-cli bower`.
We also advise against running as root user. NPM deliberately uses limited privileges when executing certain commands such as those included in the Roots post-install process, and when this happens to the root user, any file system objects that are not expressly writable by the root user will fail to write during the execution of the command. These might include directories such as `/var/www` or `/home/someotheruser`. If you're running as root and have problems, don't say we didn't warn you.
### Available Grunt commands
* `grunt dev` — Compile LESS to CSS, concatenate and validate JS