forked from grommet/grommet
-
Notifications
You must be signed in to change notification settings - Fork 0
Building Grommet
Alan Souza edited this page May 13, 2015
·
19 revisions
To build Grommet in your local environment, execute the following commands:
-
Install Ruby. (version 1.9.3+ required)
-
Install the Ruby scss-lint package:
```
$ gem install scss_lint
```
- Clone Grommet repo:
```
$ git clone https://github.com/HewlettPackard/grommet.git
```
- Install NPM packages:
```
$ cd grommet
$ npm install
```
- Create the NPM distribution:
```
$ gulp dist
```
This step will create the **dist** folder with content ready to be deployed in NPM.
- Create the Bower distribution:
```
$ gulp dist-bower
```
This step will create the **dist-bower** folder with content ready to be used or deployed in Bower.
To run the Grommet website locally, execute the following commands:
- Inside your local Grommet directory, access the docs folder:
```
$ cd docs
```
- Run the website using Hot Module Replacement:
```
$ gulp dev
```
This will start a development server with generic Grommet styling, if you want to use the HPE style, run the following command instead:
```
$ gulp dev-hpe
```
- Open Grommet Website
At this point, any modification in the website will trigger automatic reload in the browser so that you can easily validate your changes. This is very handy, isn't it?
- Build the website for distribution:
```
$ gulp dist
```
This step will create a **docs/dist** folder with the content ready to be deployed in an application server of your choice.
Tests are located in the test folder. You can execute them by running the following command:
$ gulp test
This step will create a code coverage report under test/coverage.html.
The Grommet team is looking forward to your contributions. If you are interested in contributing while getting comfortable with the platform, consider adding to the unit test library. We believe a good way to learn a new framework is by writing tests for it.