Add and update a list of files into git exclude
This plugin requires Grunt ~0.4.1
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 git+https://git@github.com/debugwand/grunt-gitexclude.git --save-dev
Once the plugin has been installed, it may be enabled inside your Gruntfile with this line of JavaScript:
grunt.loadNpmTasks('grunt-gitexclude');
In your project's Gruntfile, add a section named gitexclude
to the data object passed into grunt.initConfig()
.
grunt.initConfig({
gitexclude: {
options: {
id: "unique_identifier_for_the_list_of_files_to_ignore"
},
your_target: {
destDir: 'foo/bar', //project folder where .git folder can be found. don't include .git/info/exclude, that is handled in the code
src: ['folder/file', 'folder/folder'] //lines to add to git exclude
},
},
})
Type: String
Default value: ''
A string value that is used to demark the start and end of your list of files in the exclude file. This allows you to overwrite a block when you run the task rather than continually append to the file.
0.1.0 first release