<commit_before>module.exports = function(grunt) {
    var pkg = grunt.file.readJSON('package.json')
    grunt.initConfig({
        version: [ pkg.version, pkg.buildNum ].join('.') //
        ,
        buildNum: parseInt(pkg.buildNum)
        ,
        dist: 'dist' //
        ,
        filename: pkg.name //

        // 合并 js 文件
        // 文档 https://github.com/gruntjs/grunt-contrib-concat
        ,
        concat: {
            dist: {
                options: {
                    // banner: '<%= meta.modules %>\n'
                },
                src: [
                    'src/begin.js',
                    "src/lib/*.js",
                    'src/izhihu.js',
                    "src/modules/*.js",
                    "src/pages/*.js",
                    "src/end.js"
                ], //src filled in by build task
                dest: '<%= dist %>/<%= filename %>.js'
            },
            distUserscript: {
                src: [
                    "src/meta.js",
                    "<%= dist %>/<%= filename %>.js"
                ], //src filled in by build task
                dest: '<%= dist %>/<%= filename %>.userscript.js'
            }
        }
        // 压缩 js 文件
        // 文档 https://github.com/gruntjs/grunt-contrib-uglify
        ,
        uglify: {
            options: {
                mangle: true, // 是否替换变量名
                report: 'gzip'
            },
            dist: {
                src: ['<%= dist %>/<%= filename %>.js'],
                dest: '<%= dist %>/<%= filename %>.min.js'
            },
        }<commit_msg>- changed filename of dest js for distUserscipt to "*.user.js"<commit_after>module.exports = function(grunt) {
    var pkg = grunt.file.readJSON('package.json')
    grunt.initConfig({
        version: [ pkg.version, pkg.buildNum ].join('.') //
        ,
        buildNum: parseInt(pkg.buildNum)
        ,
        dist: 'dist' //
        ,
        filename: pkg.name //

        // 合并 js 文件
        // 文档 https://github.com/gruntjs/grunt-contrib-concat
        ,
        concat: {
            dist: {
                options: {
                    // banner: '<%= meta.modules %>\n'
                },
                src: [
                    'src/begin.js',
                    "src/lib/*.js",
                    'src/izhihu.js',
                    "src/modules/*.js",
                    "src/pages/*.js",
                    "src/end.js"
                ], //src filled in by build task
                dest: '<%= dist %>/<%= filename %>.js'
            },
            distUserscript: {
                src: [
                    "src/meta.js",
                    "<%= dist %>/<%= filename %>.js"
                ], //src filled in by build task
                dest: '<%= dist %>/<%= filename %>.user.js'
            }
        }
        // 压缩 js 文件
        // 文档 https://github.com/gruntjs/grunt-contrib-uglify
        ,
        uglify: {
            options: {
                mangle: true, // 是否替换变量名
                report: 'gzip'
            },
            dist: {
                src: ['<%= dist %>/<%= filename %>.js'],
                dest: '<%= dist %>/<%= filename %>.min.js'
            },
        }
{'fraction_non_alphanumeric': 0.1585709808837355, 'fraction_numerical': 0.0, 'mean_word_length': 0.9357186173438448, 'pattern_counts': {'":': 0, '<': 25, '<?xml version=': 0, '>': 25, 'https://': 4, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2919699', 'n_tokens_mistral': 999, 'n_tokens_neox': 932, 'n_words': 171}