Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

grunt-gh-deploy

Package Overview
Dependencies
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

grunt-gh-deploy

Grunt plugin for easy deployment to Github gh-pages branch.

  • 0.1.3
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
0
decreased by-100%
Maintainers
1
Weekly downloads
 
Created
Source

grunt-gh-deploy Build Status

Grunt plugin for easy deployment to ghPages branch.

Getting Started

This plugin requires Grunt ~0.4.5

If you haven't used Grunt before, be sure to check out the Getting Started guide, as it explains how to create a Gruntfile as well as install and use Grunt plugins. Once you're familiar with that process, you may install this plugin with this command:

npm install grunt-gh-deploy --save-dev

Once the plugin has been installed, it may be enabled inside your Gruntfile with this line of JavaScript:

grunt.loadNpmTasks('grunt-gh-deploy');

The "ghDeploy" task

Overview

In your project's Gruntfile, add a section named ghDeploy to the data object passed into grunt.initConfig().

grunt.initConfig({
    ghDeploy: {
        // Task options go here
    },
});

Options

options.repository

Type: String Default value: null

A path to Git repository to deploy to. Can be local file system repository (absolute path) or remote URL.

options.branch

Type: String Default value: 'gh-pages'

The name of the branch in the repository to deploy to.

options.deployPath

Type: String Default value: null

Path to the folder with build files to deploy, relative to Gruntfile. Typically this is a result of previous build task.

options.message

Type: String Default value: 'Deployment ' + grunt.template.today()

Commit message to deployment branch.

Usage Examples

Default Options

The minimum configuration must include the path to repository and path to directory with files to deploy. For example:

ghDeploy: {
	options: {
		repository: 'https://github.com/dfsq/angular-google-tasks.git',
		deployPath: 'dist'
	}
},
Other options

There are several additional configuration options: name of the branch to push deployed files and optional commit message.

grunt.initConfig({
    ghDeploy: {
    	repository: 'https://github.com/dfsq/angular-google-tasks.git',
    	branch: 'release-branch',
    	deployPath: 'dist',
    	message: 'Auto deplyment ' + grunt.template.today()
    }
});
Notes

Depending on your system git setup you may be asked to input github username and password before pushing to remote repository.

Contributing

In lieu of a formal styleguide, take care to maintain the existing coding style. Add unit tests for any new or changed functionality. Lint and test your code using Grunt.

Release History

2014-11-14  v0.1.0 Initial basic version is released.

Keywords

FAQs

Package last updated on 19 Jun 2015

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc