Completed
Push — master ( 234952...c4c208 )
by Sudar
01:21
created

Gruntfile.js   A

Complexity

Total Complexity 1
Complexity/F 1

Size

Lines of Code 64
Function Count 1

Duplication

Duplicated Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
cc 0
nc 1
dl 0
loc 64
rs 10
c 1
b 0
f 0
wmc 1
mnd 0
bc 1
fnc 1
bpm 1
cpm 1
noi 0
1
/* global module, require */
2
module.exports = function( grunt ) {
3
	'use strict';
4
5
	// Load all grunt tasks
6
	require('matchdep').filterDev('grunt-*').forEach(grunt.loadNpmTasks);
7
8
	// Project configuration
9
	grunt.initConfig( {
10
		pkg:    grunt.file.readJSON( 'package.json' ),
11
12
		clean   : {
13
			dist: ['dist/']
14
		},
15
16
		copy: {
17
			dist: {
18
				files : [
19
					{
20
						expand: true,
21
						src: [
22
							'**',
23
							'!dist/**',
24
							'!AUTHORS.md',
25
							'!assets-wp-repo/**',
26
							'!code-coverage/**',
27
							'!codeception.yml',
28
							'!node_modules/**',
29
							'!assets/vendor/**',
30
							'!assets/js/src/**',
31
							'!assets/css/src/**',
32
							'!Gruntfile.js',
33
							'!bower.json',
34
							'!package.json',
35
							'!package-lock.json',
36
							'!composer.json',
37
							'!composer.lock',
38
							'!phpcs.xml',
39
							'!phpdoc.dist.xml',
40
							'!phpunit.xml.dist',
41
							'!bin/**',
42
							'!tests/**',
43
							'!.idea/**',
44
							'!tags',
45
							'!vendor/**'
46
						],
47
						dest: 'dist/'
48
					}
49
				]
50
			}
51
		},
52
		watch: {
53
			all: {
54
				files: ['**', '!dist/**'],
55
				tasks: ['build']
56
			}
57
		}
58
	} );
59
60
	require('time-grunt')(grunt);
61
62
	grunt.registerTask('build', ['clean', 'copy:dist']);
63
64
	grunt.util.linefeed = '\n';
65
};
66