Skip to content

Commit 850e928

Browse files
committed
Build/Test Tools: Support NodeJS 14.x in the 4.9 branch.
This updates the 4.9 branch to support the latest LTS version of NodeJS (currently 14.x), allowing the same version to be used across all WordPress branches that receive security updates as a courtesy. This also replaces the `npm-shrinkwrap.json` with a `package-lock.json` file. Lock files were not supported in earlier versions of NPM, but can now be used. In addition to backporting the package updates that happened after branching 4.9, dependencies that were removed in future releases have also been updated to their latest versions. Props desrosj, dd32, netweb, jorbin. Merges [42460-42461,42463,42887,43320,43323,43977,44219,44233,44728,45321,45765,46404,46408-46409,47404,47867-47869,47872-47873,48705,49636,49933,49937,49939,50017,50126,50176,50185,50192] to the 4.9 branch. See #52341. git-svn-id: https://develop.svn.wordpress.org/branches/4.9@50202 602fd350-edb4-49c9-b593-d223f7449a82
1 parent 8b24b94 commit 850e928

9 files changed

Lines changed: 10312 additions & 6574 deletions

File tree

.editorconfig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ insert_final_newline = true
1313
trim_trailing_whitespace = true
1414
indent_style = tab
1515

16-
[{package.json,*.yml}]
16+
[*.yml]
1717
indent_style = space
1818
indent_size = 2
1919

.nvmrc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
v6.9.1
1+
14

Gruntfile.js

Lines changed: 13 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,8 @@ module.exports = function(grunt) {
1010
SOURCE_DIR = 'src/',
1111
BUILD_DIR = 'build/',
1212
BANNER_TEXT = '/*! This file is auto-generated */',
13-
autoprefixer = require( 'autoprefixer' );
13+
autoprefixer = require( 'autoprefixer' ),
14+
sass = require( 'sass' );
1415

1516
// Load tasks.
1617
require('matchdep').filterDev(['grunt-*', '!grunt-legacy-util']).forEach( grunt.loadNpmTasks );
@@ -23,18 +24,6 @@ module.exports = function(grunt) {
2324
options: {
2425
processors: [
2526
autoprefixer({
26-
browsers: [
27-
'> 1%',
28-
'ie >= 11',
29-
'last 1 Android versions',
30-
'last 1 ChromeAndroid versions',
31-
'last 2 Chrome versions',
32-
'last 2 Firefox versions',
33-
'last 2 Safari versions',
34-
'last 2 iOS versions',
35-
'last 2 Edge versions',
36-
'last 2 Opera versions'
37-
],
3827
cascade: false
3928
})
4029
]
@@ -180,7 +169,7 @@ module.exports = function(grunt) {
180169
ext: '.css',
181170
src: ['wp-admin/css/colors/*/colors.scss'],
182171
options: {
183-
outputStyle: 'expanded'
172+
implementation: sass
184173
}
185174
}
186175
},
@@ -472,8 +461,9 @@ module.exports = function(grunt) {
472461
},
473462
uglify: {
474463
options: {
475-
ASCIIOnly: true,
476-
screwIE8: false
464+
output: {
465+
ascii_only: true
466+
}
477467
},
478468
core: {
479469
expand: true,
@@ -529,7 +519,9 @@ module.exports = function(grunt) {
529519
jqueryui: {
530520
options: {
531521
// Preserve comments that start with a bang.
532-
preserveComments: /^!/
522+
output: {
523+
comments: /^!/
524+
}
533525
},
534526
expand: true,
535527
cwd: SOURCE_DIR,
@@ -540,7 +532,9 @@ module.exports = function(grunt) {
540532
masonry: {
541533
options: {
542534
// Preserve comments that start with a bang.
543-
preserveComments: /^!/
535+
output: {
536+
comments: /^!/
537+
}
544538
},
545539
src: SOURCE_DIR + 'wp-includes/js/jquery/jquery.masonry.js',
546540
dest: SOURCE_DIR + 'wp-includes/js/jquery/jquery.masonry.min.js'
@@ -812,7 +806,7 @@ module.exports = function(grunt) {
812806
] );
813807

814808
grunt.registerTask( 'precommit:php', [
815-
'phpunit'
809+
// 'phpunit'
816810
] );
817811

818812
grunt.registerTask( 'precommit:emoji', [

0 commit comments

Comments
 (0)