<commit_before>#!/usr/bin/env node
'use strict'

const fs = require('fs')

const templates = require('./templates.js');

const log = (...args) => {console.log(...args)}
const logError = (...args) => {console.error(...args)}

const handleFileWritingErr = (err) => {
	switch (err.code) {
		case 'EEXIST':
			logError(`A file named ${err.path} already exists!`)
			break
		default:
			logError(err)
	}
}

const main = (args) => {
	if (!args || args.length < 3) {
		return printUsage()
	}

	switch (args[2]) {
		case 'g': case 'generate':
			generate(args.slice(3))
			break
		default:
			printUsage()
	}
}

const printUsage = () => {
	log('I should explain usage here')
}

const generate = (args) => {
	if (!args || args.length < 2) {<commit_msg>add default behavior to simplify usage<commit_after>#!/usr/bin/env node
'use strict'

const fs = require('fs')

const templates = require('./templates.js');

const log = (...args) => {console.log(...args)}
const logError = (...args) => {console.error(...args)}

const handleFileWritingErr = (err) => {
	switch (err.code) {
		case 'EEXIST':
			logError(`A file named ${err.path} already exists!`)
			break
		default:
			logError(err)
	}
}

const main = (args) => {
	if (!args || args.length < 3) {
		return printUsage()
	}

	switch (args[2]) {
		case 'g': case 'generate':
			generate(args.slice(3))
			break
		default:
			if (args.length == 3) {
				generateComponents([args[2]]);
			} else {
				printUsage()
			}
	}
}

const printUsage = () => {
	log('I should explain usage here')
}

const generate = (args) => {
	if (!args || args.length < 2) {
{'fraction_non_alphanumeric': 0.1935889377749843, 'fraction_numerical': 0.006285355122564425, 'mean_word_length': 3.337874659400545, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 15, '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': '3245209', 'n_tokens_mistral': 621, 'n_tokens_neox': 564, 'n_words': 144}