<commit_before>'use strict';
var util = require('util'),
path = require('path'),
yeoman = require('yeoman-generator'),
childProcess = require('child_process'),
chalk = require('chalk'),
_s = require('underscore.string'),
scriptBase = require('../script-base');

var exec = childProcess.exec;
var spawn = childProcess.spawn;

var OpenshiftGenerator = module.exports = function OpenshiftGenerator() {
    yeoman.generators.Base.apply(this, arguments);
    console.log(chalk.bold('Openshift configuration is starting'));
    this.env.options.appPath = this.config.get('appPath') || 'src/main/webapp';
    this.baseName = this.config.get('baseName');
    this.packageName = this.config.get('packageName');
    this.packageFolder = this.config.get('packageFolder');
    this.javaVersion = this.config.get('javaVersion');
    this.hibernateCache = this.config.get('hibernateCache');
    this.databaseType = this.config.get('databaseType');
    this.angularAppName = _s.camelize(_s.slugify(this.baseName)) + 'App';
};

util.inherits(OpenshiftGenerator, yeoman.generators.Base);
util.inherits(OpenshiftGenerator, scriptBase);

OpenshiftGenerator.prototype.askForName = function askForName() {
    var done = this.async();

    var prompts = [{
        name: 'openShiftDeployedName',
        message: 'Name to deploy as:',
        default: this.baseName
    }];

    this.prompt(prompts, function (props) {
        this.openShiftDeployedName = this._.slugify(props.openShiftDeployedName).split('-').join('');
        done();
    }.bind(this));
};

OpenshiftGenerator.prototype.checkInstallation = function checkInstallation() {
    if(this.abort) return;
    var done = this.async();

    exec('rhc --version', function (err) {
        if (err) {
            this.log.error('Openshift\'s rhc command line interface is not available. ' +
            'You can install it via RubyGems with: gem install rhc');
            this.abort = true;
        }
        done();
    }.bind(this));
};

OpenshiftGenerator.prototype.gitInit = function gitInit() {
    if(this.abort) return;
    var done = this.async();

    this.log(chalk.bold('Initializing deployment repo'));
    this.mkdir('deploy/openshift');
    exec('git init', { cwd: 'deploy/openshift' }, function (err, stdout, stderr) {
        this.log(stdout);
        done();
    }.bind(this));
};
<commit_msg>Only mkdir since the git repository will be cloned from openshift<commit_after>'use strict';
var util = require('util'),
path = require('path'),
yeoman = require('yeoman-generator'),
childProcess = require('child_process'),
chalk = require('chalk'),
_s = require('underscore.string'),
scriptBase = require('../script-base');

var exec = childProcess.exec;
var spawn = childProcess.spawn;

var OpenshiftGenerator = module.exports = function OpenshiftGenerator() {
    yeoman.generators.Base.apply(this, arguments);
    console.log(chalk.bold('Openshift configuration is starting'));
    this.env.options.appPath = this.config.get('appPath') || 'src/main/webapp';
    this.baseName = this.config.get('baseName');
    this.packageName = this.config.get('packageName');
    this.packageFolder = this.config.get('packageFolder');
    this.javaVersion = this.config.get('javaVersion');
    this.hibernateCache = this.config.get('hibernateCache');
    this.databaseType = this.config.get('databaseType');
    this.angularAppName = _s.camelize(_s.slugify(this.baseName)) + 'App';
};

util.inherits(OpenshiftGenerator, yeoman.generators.Base);
util.inherits(OpenshiftGenerator, scriptBase);

OpenshiftGenerator.prototype.askForName = function askForName() {
    var done = this.async();

    var prompts = [{
        name: 'openShiftDeployedName',
        message: 'Name to deploy as:',
        default: this.baseName
    }];

    this.prompt(prompts, function (props) {
        this.openShiftDeployedName = this._.slugify(props.openShiftDeployedName).split('-').join('');
        done();
    }.bind(this));
};

OpenshiftGenerator.prototype.checkInstallation = function checkInstallation() {
    if(this.abort) return;
    var done = this.async();

    exec('rhc --version', function (err) {
        if (err) {
            this.log.error('Openshift\'s rhc command line interface is not available. ' +
            'You can install it via RubyGems with: gem install rhc');
            this.abort = true;
        }
        done();
    }.bind(this));
};

OpenshiftGenerator.prototype.dirInit = function dirInit() {
    if(this.abort) return;
    var done = this.async();

    this.log(chalk.bold('Initializing deployment repo'));
    this.mkdir('deploy/openshift');
    done();
};

{'fraction_non_alphanumeric': 0.15121317157712305, 'fraction_numerical': 0.0, 'mean_word_length': 3.764705882352941, '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': '4075022', 'n_tokens_mistral': 1436, 'n_tokens_neox': 1396, 'n_words': 278}