<commit_before>'use strict';

var shell = require('shelljs');
var path = require('path');
var fs = require('fs');
var store = require('./module_store');
var mkdirp = require('mkdirp');

// TODO: set the appropriate path for the os
var modules_dir = '/usr/local/lib/atomar_modules';

var spec = {
    controllers_dir: 'controllers',
    views_dir: 'views',
    package_file: 'atomar.json'
};

/**
 * Converts a string into a class name
 * @param string
 */
function className(string) {
    return string.replace(/[^a-zA-Z0-9]+/g, '');
}

/**
 * Converts a string to a machine safe name
 * @param string
 */
function machineName(string) {
    return string.replace(/[^a-zA-Z]+/g, '_').replace(/(^_|_$)/g, '').toLowerCase();<commit_msg>added support for numbers in machine name<commit_after>'use strict';

var shell = require('shelljs');
var path = require('path');
var fs = require('fs');
var store = require('./module_store');
var mkdirp = require('mkdirp');

// TODO: set the appropriate path for the os
var modules_dir = '/usr/local/lib/atomar_modules';

var spec = {
    controllers_dir: 'controllers',
    views_dir: 'views',
    package_file: 'atomar.json'
};

/**
 * Converts a string into a class name
 * @param string
 */
function className(string) {
    return string.replace(/[^a-zA-Z0-9]+/g, '');
}

/**
 * Converts a string to a machine safe name
 * @param string
 */
function machineName(string) {
    return string.replace(/[^a-zA-Z0-9]+/g, '_').replace(/(^_|_$)/g, '').replace(/^[0-9]+]/g, '').toLowerCase();
{'fraction_non_alphanumeric': 0.18725361366622864, 'fraction_numerical': 0.005256241787122208, 'mean_word_length': 4.026402640264027, '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': '1096687', 'n_tokens_mistral': 517, 'n_tokens_neox': 507, 'n_words': 136}