-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathtemplate.js
35 lines (31 loc) · 886 Bytes
/
template.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
/*
* grunt-init-craft
* http://github.com/pennebaker/
*
* Copyright (c) 2015 Pennebaker
* Licensed under the MIT license.
*/
'use strict';
// Basic template description.
exports.description = 'Scaffolding for Craft local development.';
// Any existing file or directory matching this wildcard will cause a warning.
exports.warnOn = '*';
// The actual init template.
exports.template = function(grunt, init, done) {
init.process({}, [
// Prompt for these values.
init.prompt('name'),
init.prompt('author_name'),
init.prompt('author_email'),
init.prompt('domain_name'),
init.prompt('domain_tld'),
init.prompt('server_user')
], function(err, props) {
// Files to copy (and process).
var files = init.filesToCopy(props);
// Actually copy (and process) files.
init.copyAndProcess(files, props);
// All done!
done();
});
};