Make WordPress Core

Ticket #26751: 26751.3.patch

File 26751.3.patch, 746 bytes (added by azaozz, 12 years ago)
  • Gruntfile.js

     
    7979                        version: {
    8080                                options: {
    8181                                        processContent: function( src ) {
    82                                                 return src.replace( /^(\$wp_version.+?)-src';/m, '$1\';' );
     82                                                return src.replace( /^\$wp_version = '(.+?)';/m, function( str, version ) {
     83                                                        version = version.replace( /-src$/, '' );
     84
     85                                                        // If the version includes a date string (-yyyymmdd), update it.
     86                                                        version = version.replace( /-[\d]{8}$/, '-' + grunt.template.today( 'yyyymmdd' ) );
     87
     88                                                        return "$wp_version = '" + version + "';";
     89                                                });
    8390                                        }
    8491                                },
    8592                                src: SOURCE_DIR + 'wp-includes/version.php',