Skip to content
This repository has been archived by the owner on Sep 13, 2019. It is now read-only.

Latest commit

 

History

History
72 lines (42 loc) · 2.36 KB

CONTRIBUTING.md

File metadata and controls

72 lines (42 loc) · 2.36 KB

Contributing

Local Development Environment

WP Gist, both the plugin and the website, is built using Ruby (needed for Sass compilation), Node.js & NPM, Bower, Grunt, Sass, and Jekyll.

If you wish to contribute to the project, you'll need to install these components.

Install Ruby

Mac:

  1. Mac's already come with Ruby installed, so there is nothing for you to do!

Windows:

  1. Install Ruby Installer.

Install NPM

Mac:

  1. Install Homebrew by running the following command: ruby -e "$(curl -fsSL https://raw.github.com/Homebrew/homebrew/go/install)"
  2. Install Node.js and NPM by running the following command: brew install node

Windows:

  1. Head to the Node.js Download page
  2. Click on "Windows Installer" to begin downloading
  3. Run installer to install Node.js and NPM

Install Bower

Run the following command: npm install -g bower

Install Grunt

Run the following command: npm install -g grunt-cli

Install Sass

Run the following command: gem install sass

Install Jekyll

Run the following command: gem install jekyll

Plugin Development

After everything above is installed, You need to:

  1. Fork and clone the WP Gist repository
  2. Navigate to the local WP Gist directory via command line
  3. Run the following commands to build the environment
    • npm install
    • grunt

This will download the project dependencies and build the project.

A full list of Grunt tasks are available in the grunt/tasks.js file within the project. You'll use the grunt and grunt build commands most often.

When committing your changes, please make a pull request to the master branch, unless otherwise specified.

GitHub Pages Development

  1. Navigate to the local WP Gist directory via command line
  2. Make sure the gh-pages branch is checked out
  3. Run the jekyll serve --watch command to start Jekyll and have it watch for changes, which will auto regenerate pages
  4. Go to http://localhost:4000/ in your browser to see the WP Gist GitHub Page
  5. Use ⌃C (Mac) or Ctrl+C (Windows) to stop the local server.

When committing your changes, please make a pull request to the gh-pages branch.