<commit_before>'use strict';

module.exports = function(grunt) {
    // Load any grunt plugins found in package.json.
    require('load-grunt-tasks')(grunt);
    require('time-grunt')(grunt);

    grunt.initConfig({
        dirs: {
            dest: '_site',
            src: 'source'
        },

        jekyll: {
            site: {
                options: {
                    bundleExec: true,
                    incremental: false
                }
            }
        },

        htmlmin: {
            dist: {
                options: {
                    collapseBooleanAttributes: true,
                    collapseWhitespace: true,
                    conservativeCollapse: false,
                    decodeEntities: true,
                    ignoreCustomComments: [/^\s*google(off|on):\s/],
                    minifyCSS: {
                        level: {
                            1: {
                                specialComments: 0
                            }
                        }
                    },
                    minifyJS: true,
                    minifyURLs: false,
                    processConditionalComments: true,
                    removeAttributeQuotes: true,
                    removeComments: true,
                    removeOptionalAttributes: true,
                    removeOptionalTags: true,
                    removeRedundantAttributes: true,
                    removeScriptTypeAttributes: true,
                    removeStyleLinkTypeAttributes: true,
                    removeTagWhitespace: false,
                    sortAttributes: true,
                    sortClassName: true
                },
                expand: true,
                cwd: '<%= dirs.dest %>',
                dest: '<%= dirs.dest %>',
                src: ['**/*.html', '**/*.php']
            }
        },

        concat: {
            css: {
                src: [
                    '<%= dirs.src %>/assets/css/vendor/font-awesome.css',
                    '<%= dirs.src %>/assets/css/vendor/bootstrap.css',
                    '<%= dirs.src %>/assets/css/vendor/baguetteBox.css',
                    '<%= dirs.src %>/assets/css/fonts.css',
                    '<%= dirs.src %>/assets/css/style.css'
                ],
                dest: '<%= dirs.dest %>/assets/css/pack.css'
            },
            jqueryJS: {
                src: [
                    '<%= dirs.src %>/assets/js/vendor/jquery.slim.min.js',
                    '<%= dirs.src %>/assets/js/vendor/bootstrap.js',
                    '<%= dirs.src %>/assets/js/downloads.js'
                ],
                dest: '<%= dirs.dest %>/assets/js/jquery-pack.js'
            },
            js: {
                src: [
                    '<%= dirs.src %>/assets/js/vendor/plugins.js',
                    '<%= dirs.src %>/assets/js/vendor/baguetteBox.js',
                    '<%= dirs.src %>/assets/js/baguetteBox-init.js',
                    '<%= dirs.src %>/assets/js/detect-os.js',
                    '<%= dirs.src %>/assets/js/img-defer.js',
                    '<%= dirs.src %>/assets/js/no-js-class.js',
                    '<%= dirs.src %>/assets/js/google-analytics.js'
                ],
                dest: '<%= dirs.dest %>/assets/js/pack.js'
            },
            sw: {
                src: [
                    '<%= dirs.src %>/assets/js/sw.js'
                ],
                dest: '<%= dirs.dest %>/sw.min.js'
            }
        },

        postcss: {
            options: {
                processors: [
                    require('postcss-combine-duplicated-selectors')({ removeDuplicatedProperties: true }), // combine duplicate selectors
                    require('autoprefixer')() // add vendor prefixes
                ]
            },
            dist: {
                src: '<%= concat.css.dest %>'
            }
        },

        purgecss: {
            dist: {
                options: {
                    content: [
                        '<%= dirs.dest %>/**/*.html',
                        '<%= dirs.dest %>/assets/js/**/*.js'
                    ],
                    keyframes: true,
                    whitelistPatternsChildren: [
                        /bounce-from-/
                    ]
                },
                files: {
                    '<%= concat.css.dest %>': ['<%= concat.css.dest %>']
                }
            }
        },

        cssmin: {
            minify: {
                options: {
                    level: {
                        1: {
                            specialComments: 0
                        }
                    }
                },
                files: {
                    '<%= concat.css.dest %>': '<%= concat.css.dest %>'<commit_msg>Update clean-css config<commit_after>'use strict';

module.exports = function(grunt) {
    // Load any grunt plugins found in package.json.
    require('load-grunt-tasks')(grunt);
    require('time-grunt')(grunt);

    grunt.initConfig({
        dirs: {
            dest: '_site',
            src: 'source'
        },

        jekyll: {
            site: {
                options: {
                    bundleExec: true,
                    incremental: false
                }
            }
        },

        htmlmin: {
            dist: {
                options: {
                    collapseBooleanAttributes: true,
                    collapseWhitespace: true,
                    conservativeCollapse: false,
                    decodeEntities: true,
                    ignoreCustomComments: [/^\s*google(off|on):\s/],
                    minifyCSS: {
                        level: {
                            1: {
                                specialComments: 0,
                                roundingPrecision: 6
                            },
                            2: {
                                all: false,
                                mergeMedia: true,
                                removeDuplicateMediaBlocks: true,
                                removeEmpty: true
                            }
                        }
                    },
                    minifyJS: true,
                    minifyURLs: false,
                    processConditionalComments: true,
                    removeAttributeQuotes: true,
                    removeComments: true,
                    removeOptionalAttributes: true,
                    removeOptionalTags: true,
                    removeRedundantAttributes: true,
                    removeScriptTypeAttributes: true,
                    removeStyleLinkTypeAttributes: true,
                    removeTagWhitespace: false,
                    sortAttributes: true,
                    sortClassName: true
                },
                expand: true,
                cwd: '<%= dirs.dest %>',
                dest: '<%= dirs.dest %>',
                src: ['**/*.html', '**/*.php']
            }
        },

        concat: {
            css: {
                src: [
                    '<%= dirs.src %>/assets/css/vendor/font-awesome.css',
                    '<%= dirs.src %>/assets/css/vendor/bootstrap.css',
                    '<%= dirs.src %>/assets/css/vendor/baguetteBox.css',
                    '<%= dirs.src %>/assets/css/fonts.css',
                    '<%= dirs.src %>/assets/css/style.css'
                ],
                dest: '<%= dirs.dest %>/assets/css/pack.css'
            },
            jqueryJS: {
                src: [
                    '<%= dirs.src %>/assets/js/vendor/jquery.slim.min.js',
                    '<%= dirs.src %>/assets/js/vendor/bootstrap.js',
                    '<%= dirs.src %>/assets/js/downloads.js'
                ],
                dest: '<%= dirs.dest %>/assets/js/jquery-pack.js'
            },
            js: {
                src: [
                    '<%= dirs.src %>/assets/js/vendor/plugins.js',
                    '<%= dirs.src %>/assets/js/vendor/baguetteBox.js',
                    '<%= dirs.src %>/assets/js/baguetteBox-init.js',
                    '<%= dirs.src %>/assets/js/detect-os.js',
                    '<%= dirs.src %>/assets/js/img-defer.js',
                    '<%= dirs.src %>/assets/js/no-js-class.js',
                    '<%= dirs.src %>/assets/js/google-analytics.js'
                ],
                dest: '<%= dirs.dest %>/assets/js/pack.js'
            },
            sw: {
                src: [
                    '<%= dirs.src %>/assets/js/sw.js'
                ],
                dest: '<%= dirs.dest %>/sw.min.js'
            }
        },

        postcss: {
            options: {
                processors: [
                    require('postcss-combine-duplicated-selectors')({ removeDuplicatedProperties: true }), // combine duplicate selectors
                    require('autoprefixer')() // add vendor prefixes
                ]
            },
            dist: {
                src: '<%= concat.css.dest %>'
            }
        },

        purgecss: {
            dist: {
                options: {
                    content: [
                        '<%= dirs.dest %>/**/*.html',
                        '<%= dirs.dest %>/assets/js/**/*.js'
                    ],
                    keyframes: true,
                    whitelistPatternsChildren: [
                        /bounce-from-/
                    ]
                },
                files: {
                    '<%= concat.css.dest %>': ['<%= concat.css.dest %>']
                }
            }
        },

        cssmin: {
            minify: {
                options: {
                    level: {
                        1: {
                            specialComments: 0,
                            roundingPrecision: 6
                        },
                        2: {
                            all: false,
                            mergeMedia: true,
                            removeDuplicateMediaBlocks: true,
                            removeEmpty: true
                        }
                    }
                },
                files: {
                    '<%= concat.css.dest %>': '<%= concat.css.dest %>'
{'fraction_non_alphanumeric': 0.1275740341243381, 'fraction_numerical': 0.001176701313983134, 'mean_word_length': 0.8290889526542324, 'pattern_counts': {'":': 0, '<': 61, '<?xml version=': 0, '>': 61, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 2, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3652403', 'n_tokens_mistral': 2752, 'n_tokens_neox': 2514, 'n_words': 370}