|
1 | 1 | module.exports = function (grunt) {
|
2 |
| - // Project configuration. |
3 |
| - grunt.initConfig({ |
4 |
| - checktextdomain: { |
5 |
| - options:{ |
6 |
| - text_domain: 'indieauth', |
7 |
| - keywords: [ |
8 |
| - '__:1,2d', |
9 |
| - '_e:1,2d', |
10 |
| - '_x:1,2c,3d', |
11 |
| - 'esc_html__:1,2d', |
12 |
| - 'esc_html_e:1,2d', |
13 |
| - 'esc_html_x:1,2c,3d', |
14 |
| - 'esc_attr__:1,2d', |
15 |
| - 'esc_attr_e:1,2d', |
16 |
| - 'esc_attr_x:1,2c,3d', |
17 |
| - '_ex:1,2c,3d', |
18 |
| - '_n:1,2,4d', |
19 |
| - '_nx:1,2,4c,5d', |
20 |
| - '_n_noop:1,2,3d', |
21 |
| - '_nx_noop:1,2,3c,4d' |
22 |
| - ] |
23 |
| - }, |
24 |
| - files: { |
25 |
| - src: [ |
26 |
| - '**/*.php', // Include all files |
27 |
| - 'includes/*.php', // Include includes |
28 |
| - '!node_modules/**', // Exclude node_modules/ |
29 |
| - '!tests/**', // Exclude tests/ |
30 |
| - '!vendor/**', // Exclude vendor/ |
31 |
| - '!static/**', // Exclude static resources |
32 |
| - ], |
33 |
| - expand: true |
34 |
| - } |
35 |
| - }, |
| 2 | + // Project configuration. |
| 3 | + grunt.initConfig( |
| 4 | + { |
| 5 | + files: { |
| 6 | + src: [ |
| 7 | + '**/*.php', // Include all files |
| 8 | + 'includes/*.php', // Include includes |
| 9 | + '!node_modules/**', // Exclude node_modules/ |
| 10 | + '!tests/**', // Exclude tests/ |
| 11 | + '!vendor/**', // Exclude vendor/ |
| 12 | + '!static/**', // Exclude static resources |
| 13 | + ], |
| 14 | + expand: true |
| 15 | + }, |
| 16 | + wp_readme_to_markdown: { |
| 17 | + target: { |
| 18 | + files: { |
| 19 | + 'readme.md': 'readme.txt' |
| 20 | + } |
| 21 | + } |
| 22 | + }, |
| 23 | + makepot: { |
| 24 | + target: { |
| 25 | + options: { |
| 26 | + mainFile: 'indieauth.php', |
| 27 | + domainPath: '/languages', |
| 28 | + exclude: ['build/.*'], |
| 29 | + potFilename: 'indieauth.pot', |
| 30 | + type: 'wp-plugin', |
| 31 | + updateTimestamp: true |
| 32 | + } |
| 33 | + } |
| 34 | + } |
| 35 | + } |
| 36 | + ); |
36 | 37 |
|
37 |
| - wp_readme_to_markdown: { |
38 |
| - target: { |
39 |
| - files: { |
40 |
| - 'readme.md': 'readme.txt' |
41 |
| - } |
42 |
| - } |
43 |
| - }, |
44 |
| - makepot: { |
45 |
| - target: { |
46 |
| - options: { |
47 |
| - mainFile: 'indieauth.php', |
48 |
| - domainPath: '/languages', |
49 |
| - exclude: ['build/.*'], |
50 |
| - potFilename: 'indieauth.pot', |
51 |
| - type: 'wp-plugin', |
52 |
| - updateTimestamp: true |
53 |
| - } |
54 |
| - } |
55 |
| - } |
56 |
| - }); |
57 |
| - |
58 |
| - grunt.loadNpmTasks('grunt-wp-readme-to-markdown'); |
59 |
| - grunt.loadNpmTasks('grunt-wp-i18n'); |
60 |
| - grunt.loadNpmTasks('grunt-checktextdomain'); |
61 |
| - // Default task(s). |
62 |
| - grunt.registerTask('default', ['wp_readme_to_markdown', 'makepot', 'checktextdomain']); |
| 38 | + grunt.loadNpmTasks( 'grunt-wp-readme-to-markdown' ); |
| 39 | + grunt.loadNpmTasks( 'grunt-wp-i18n' ); |
| 40 | + // Default task(s). |
| 41 | + grunt.registerTask( 'default', ['wp_readme_to_markdown','makepot'] ); |
63 | 42 | };
|
0 commit comments