Skip to content

Instantly share code, notes, and snippets.

@sudodoki
Created June 12, 2014 09:42
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save sudodoki/8e35365074e80a2e36d7 to your computer and use it in GitHub Desktop.
Save sudodoki/8e35365074e80a2e36d7 to your computer and use it in GitHub Desktop.
mytask: {
options: {},
a: {
options: {
src: "src",
dest: "dest",
match: '*'
}
},
b: {
options: {
src: "src2",
dest: "dest2",
match: '*'
}
}
},
oldtask: {
options: {
src: '',
dest: ''
}
}
grunt.task.registerTask('mytask', 'mytask descr', function () {
// get options here
this.options() // -> won't work with grunt mytask:a, but did work with grunt oldtask
})
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment