<commit_before>import ExtractTextPlugin from 'extract-text-webpack-plugin'
import WebpackNotifierPlugin from 'webpack-notifier'
import CleanWebpackPlugin from 'clean-webpack-plugin'
import CompilerPlugin from 'compiler-webpack-plugin'
import autoprefixer from 'autoprefixer'
import postcssRemify from 'postcss-remify'
import postcssEmify from 'postcss-emify'
import path from 'path'
import BrowserSyncPlugin from 'browser-sync-webpack-plugin'
import webpack from 'webpack'
import { exec } from 'child_process'
import vendor from './js/vendor'
import config from './config'

export default {
  devtool: 'source-map',
  entry: {
    bundle: './js/app.js',
    style: './scss/app.scss',
    svgxuse: './node_modules/svgxuse/svgxuse.js',
    vendor: vendor
  },
  output: {
    publicPath: '/',
    path: __dirname,
    filename: `${config.paths.dist}[name].js`
  },
  stats: {
    children: false
  },
  module: {
    loaders: [
      // Extract css files
      {
        test: /\.css$/,
        loader: ExtractTextPlugin.extract('style-loader', 'css-loader')
      },
      // Load SCSS
      {
        test: /\.scss/,
        loader: ExtractTextPlugin.extract('style-loader', 'css-loader!postcss-loader!sass-loader', { allChunks: true }),
        include: path.join(__dirname, 'scss')
      },
      {
        test: /\.js$/,
        exclude: /(node_modules)/,
        loader: 'babel-loader'
      },
      {
        test: /\.(png|jpg|gif|svg)$/,
        loader: `file-loader?name=${config.paths.publicPath}img/[name].[ext]`,
        include: path.join(__dirname, `${config.paths.publicPath}img`)
      },
      {
        test: /\.(eot|svg|ttf|woff|woff2)$/,
        loader: `file-loader?name=${config.paths.publicPath}fonts/[name].[ext]`,
        include: path.join(__dirname, `${config.paths.publicPath}fonts`)
      }
    ]
  },
  postcss: function () {
    return [
      autoprefixer,
      postcssRemify,
      postcssEmify
    ]
  },
  plugins: [
    new ExtractTextPlugin(`${config.paths.dist}[name].css`, { allChunks: false }),
    new CleanWebpackPlugin([path.join(__dirname, config.paths.dist)], {
      root: process.cwd()<commit_msg>Use loader query options instead of querystring<commit_after>import ExtractTextPlugin from 'extract-text-webpack-plugin'
import WebpackNotifierPlugin from 'webpack-notifier'
import CleanWebpackPlugin from 'clean-webpack-plugin'
import CompilerPlugin from 'compiler-webpack-plugin'
import autoprefixer from 'autoprefixer'
import postcssRemify from 'postcss-remify'
import postcssEmify from 'postcss-emify'
import path from 'path'
import BrowserSyncPlugin from 'browser-sync-webpack-plugin'
import webpack from 'webpack'
import { exec } from 'child_process'
import vendor from './js/vendor'
import config from './config'

export default {
  devtool: 'source-map',
  entry: {
    bundle: './js/app.js',
    style: './scss/app.scss',
    svgxuse: './node_modules/svgxuse/svgxuse.js',
    vendor: vendor
  },
  output: {
    publicPath: '/',
    path: __dirname,
    filename: `${config.paths.dist}[name].js`
  },
  stats: {
    children: false
  },
  module: {
    loaders: [
      // Extract css files
      {
        test: /\.css$/,
        loader: ExtractTextPlugin.extract('style-loader', 'css-loader')
      },
      // Load SCSS
      {
        test: /\.scss/,
        loader: ExtractTextPlugin.extract('style-loader', 'css-loader!postcss-loader!sass-loader', { allChunks: true }),
        include: path.join(__dirname, 'scss')
      },
      {
        test: /\.js$/,
        exclude: /(node_modules)/,
        loader: 'babel-loader'
      },
      {
        test: /\.(png|jpg|gif|svg)$/,
        loader: 'file-loader',
        query: {
          name: `${config.paths.publicPath}img/[name].[ext]`
        },
        include: path.join(__dirname, `${config.paths.publicPath}img`)
      },
      {
        test: /\.(eot|svg|ttf|woff|woff2)$/,
        loader: 'file-loader',
        query: {
          name: `${config.paths.publicPath}fonts/[name].[ext]`
        },
        include: path.join(__dirname, `${config.paths.publicPath}fonts`)
      }
    ]
  },
  postcss: function () {
    return [
      autoprefixer,
      postcssRemify,
      postcssEmify
    ]
  },
  plugins: [
    new ExtractTextPlugin(`${config.paths.dist}[name].css`, { allChunks: false }),
    new CleanWebpackPlugin([path.join(__dirname, config.paths.dist)], {
      root: process.cwd()
{'fraction_non_alphanumeric': 0.1539509536784741, 'fraction_numerical': 0.00045413260672116256, 'mean_word_length': 2.7553282182438195, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, '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': '6476784', 'n_tokens_mistral': 1439, 'n_tokens_neox': 1415, 'n_words': 275}