<commit_before>'use strict';

module.exports = function(kbox) {

  // Node
  var path = require('path');
  var os = require('os');

  // NPM
  var _ = require('lodash');
  var fs = require('fs-extra');

  // Kalabox
  var Promise = kbox.Promise;
  var events = kbox.core.events.context();
  var share = require('./share.js')(kbox);

  // Syncthing container
  var syncthingContainer = function() {
    return {
      compose: [path.resolve(__dirname, '..', 'kalabox-compose.yml')],
      project: 'kalabox',
      opts: {
        services: ['syncthing'],
        internal: true
      }
    };
  };

  /*
   * Mix in our with default syncthing config and set into the app
   */
  events.on('post-app-create', function(app) {

    // Our default syncthing configuration
    var defaultConfig = kbox.core.config.normalize({
      codeDir: 'code',
      codeRoot: path.join(app.root, ':codeDir:'),
      ignore: [
        '*.7z',
        '*.bz2',
        '*.dmg',
        '*.gz',
        '*.iso',
        '*.jar',
        '*.rar',
        '*.tar',
        '*.tgz',
        '*.un~',
        '*.zip',
        '.*.swp',
        '.*DS_Store',
        '.DS_Store*',
        '._*',
        '.sass-cache',
        'Icon',
        'Thumbs.db',
        'ehthumbs.db'
      ]
    });

    // Mix in our user config if we have it
    var config = defaultConfig;
    if (app.config.pluginconfig.sharing) {
      config = _.merge(config, app.config.pluginconfig.sharing);
    }<commit_msg>#1147: Icon can interfere with some drupal modules ie panopoly<commit_after>'use strict';

module.exports = function(kbox) {

  // Node
  var path = require('path');
  var os = require('os');

  // NPM
  var _ = require('lodash');
  var fs = require('fs-extra');

  // Kalabox
  var Promise = kbox.Promise;
  var events = kbox.core.events.context();
  var share = require('./share.js')(kbox);

  // Syncthing container
  var syncthingContainer = function() {
    return {
      compose: [path.resolve(__dirname, '..', 'kalabox-compose.yml')],
      project: 'kalabox',
      opts: {
        services: ['syncthing'],
        internal: true
      }
    };
  };

  /*
   * Mix in our with default syncthing config and set into the app
   */
  events.on('post-app-create', function(app) {

    // Our default syncthing configuration
    var defaultConfig = kbox.core.config.normalize({
      codeDir: 'code',
      codeRoot: path.join(app.root, ':codeDir:'),
      ignore: [
        '*.7z',
        '*.bz2',
        '*.dmg',
        '*.gz',
        '*.iso',
        '*.jar',
        '*.rar',
        '*.tar',
        '*.tgz',
        '*.un~',
        '*.zip',
        '.*.swp',
        '.*DS_Store',
        '.DS_Store*',
        '._*',
        '.sass-cache',
        'Thumbs.db',
        'ehthumbs.db'
      ]
    });

    // Mix in our user config if we have it
    var config = defaultConfig;
    if (app.config.pluginconfig.sharing) {
      config = _.merge(config, app.config.pluginconfig.sharing);
    }
{'fraction_non_alphanumeric': 0.1750083977158213, 'fraction_numerical': 0.0026872690628149142, 'mean_word_length': 1.9397828232971372, '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': '6944253', 'n_tokens_mistral': 1017, 'n_tokens_neox': 984, 'n_words': 218}