<commit_before>'use strict';

var fs = require('fs');
var github = require('octonode');
var path = require('path');
var rl = require('readline-sync');

var username, password, client;
var credsFile = path.join(__dirname, 'creds.file');

function deleteRepo(repo) {
    // Load the credentials/client if not initialized
    username || readCredentials();
    client = client || github.client({ username: username, password: password });
    
    // One-liner to delete the repo (where the actual work gets done)
    client.repo(repo).destroy();
}

function inferOwner(repo) {
    username || readCredentials();
    return [username, repo].join('/');
}

function loginUser() {
    console.log('Please enter your GitHub credentials.');
    username = rl.question('Username: ');
    password = rl.question('Password: ', { hideEchoBack: true }); // don't echo for password
    saveCredentials(username, password);
}

function readCredentials() {
    var contents = fs.readFileSync(credsFile, 'base64');
    var lines = contents.split('\n');<commit_msg>Fix for reading the creds file<commit_after>'use strict';

var fs = require('fs');
var github = require('octonode');
var path = require('path');
var rl = require('readline-sync');

var username, password, client;
var credsFile = path.join(__dirname, 'creds.file');

function deleteRepo(repo) {
    // Load the credentials/client if not initialized
    username || readCredentials();
    client = client || github.client({ username: username, password: password });
    
    // One-liner to delete the repo (where the actual work gets done)
    client.repo(repo).destroy();
}

function inferOwner(repo) {
    username || readCredentials();
    return [username, repo].join('/');
}

function loginUser() {
    console.log('Please enter your GitHub credentials.');
    username = rl.question('Username: ');
    password = rl.question('Password: ', { hideEchoBack: true }); // don't echo for password
    saveCredentials(username, password);
}

function readCredentials() {
    var buffer = fs.readFileSync(credsFile);
    var contents = new Buffer(buffer, 'base64').toString();
    var lines = contents.split('\n');
{'fraction_non_alphanumeric': 0.14682723483094026, 'fraction_numerical': 0.0018527095877721167, 'mean_word_length': 4.217391304347826, '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': '6559795', 'n_tokens_mistral': 609, 'n_tokens_neox': 610, 'n_words': 180}