This package has been deprecated

Author message:

This package has been deprecated: It is unuseful for grunt. Please use 'git-dependency' instead.

grunt-install-git-dependencies

0.0.1 • Public • Published

grunt-install-git-dependencies

Installs git dependencies defined in package.json. Mainly meant to get rid of bower.

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-install-git-dependencies --save-dev

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

grunt.loadNpmTasks('grunt-install-git-dependencies');

The "install_git_dependencies" task

Overview

This is a simple task for installing packages from GIT repositories, instead of requiring them via NPM. This grunt plugin does not need a Grunt config, but rather takes its configuration from package.json, to have all package dependencies in one place.

So rather than provide a Grunt config, add your config to package.json:

{
  "directories": {
    "gitDependencies": "webroot/components"
  },
  "gitDependencies": {
    "foo": "https://github.com/bylexus/foo.git#0.4.0"
  }
}

package.json configurations

directories.gitDependencies

Type: String Default value: 'components'

A (relative to the Gruntfile) path to the base directory where the GIT packages will be cloned into.

gitDependencies

Type: Object DefaultValue: {}

Object containing your GIT dependencies. The syntax for an entry is:

"[outdir]": "[git-url]#[branch-or-tag]"

Example:

  "gitDependencies": {
    "foo": "https://github.com/bylexus/foo.git#0.4.0",
    "bar": "https://github.com/bylexus/foo.git"
  }

This installs the foo repo into components/foo directory, and checks out branch or tag 0.4.0, and installs the bar repo from master to components/bar.

If the branch / tag is omitted, master is assumed.

Usage Examples

Just load the task and execute it

This task has NO own tas configuration: It is completely configured via package.json, see above.

The only thing you have to do is to load the task in your Gruntfile:

module.exports = function(grunt) {
    grunt.initConfig({
        // ....
    });

    grunt.loadNpmTasks('grunt-install-git-dependencies');
}

Then execute it:

$ grunt install-git-dependencies

Readme

Keywords

Package Sidebar

Install

npm i grunt-install-git-dependencies

Weekly Downloads

0

Version

0.0.1

License

none

Last publish

Collaborators

  • by_lexus