<commit_before>
function startCountdown() {
    var hackathonDate = new Date("December 3, 2016 00:00:00");
    var today = new Date();
    console.log(getDaysTill(hackathonDate));
    var daysLeft    = getDaysTill(hackathonDate);
    var hoursLeft   = today.getHours()   - hackathonDate.getHours();
    var minutesLeft = today.getMinutes() - hackathonDate.getMinutes();
    var secondsLeft = today.getSeconds() - hackathonDate.getSeconds();

    m = padTime(minutesLeft);
    s = padTime(secondsLeft);
    document.getElementById('countdown').innerHTML =
        "in... <br /> <br /> " +
        "<strong>"+daysLeft+"</strong>" + " days "
        +
        "<br />"
        +
        "<strong>"+hoursLeft+"</strong>" + " hours "
        +
        "<br />"
        +
        "<strong>"+minutesLeft+"</strong>" + " minutes "
        +
        "<br />"
        +
        "<strong>"+secondsLeft+"</strong>" + " seconds ";

    var t = setTimeout(startCountdown, 501);
}

/**
* Grab the days until the given date object and return. *Only works for up to a year away*
* @param {hackathonDate} hackathon date
* @return {daysTill} number of days until the hackathon date
*/
function getDaysTill(hackathonDate) {
    var currDate = new Date();
    var currMonth = currDate.getMonth()+1;
    var hackathonMonth = hackathonDate.getMonth()+1;

    //initialize days till with the days until the end of this month
    var daysTill = new Date(currDate.getFullYear(), currMonth, 0).getDate() - currDate.getDate();

    //increment month because we just added those days
    currMonth++;

    //While less than hackathon month, grab days in the month, add to total, increment currMonth
    while(currMonth < hackathonMonth) {
      daysInMonth = new Date(currDate.getFullYear(), currMonth, 0).getDate();
      daysTill += daysInMonth;
      currMonth++;
    }

    //Add the date inside the hackathon month to running total
    daysTill += hackathonDate.getDate();

    return daysTill;
}

function padTime(i) {
    // add zero in front of numbers < 10
    if (i < 10) {
      i = "0" + i
    };
    return i;
}

//Trigger the countdown timer
startCountdown();
<commit_msg>Updates to personal project using alias<commit_after>
function startCountdown() {
    var hackathonDate = new Date("December 3, 2016 00:00:00");
    var today = new Date();
    console.log(getDaysTill(hackathonDate));
    var daysLeft    = getDaysTill(hackathonDate);
    var hoursLeft   = today.getHours()   - hackathonDate.getHours();
    var minutesLeft = today.getMinutes() - hackathonDate.getMinutes();
    var secondsLeft = today.getSeconds() - hackathonDate.getSeconds();

    document.getElementById('countdown').innerHTML =
        "in... <br /> <br /> " +
        "<strong>"+daysLeft+"</strong>" + " days "
        +
        "<br />"
        +
        "<strong>"+hoursLeft+"</strong>" + " hours "
        +
        "<br />"
        +
        "<strong>"+minutesLeft+"</strong>" + " minutes "
        +
        "<br />"
        +
        "<strong>"+secondsLeft+"</strong>" + " seconds ";

    var t = setTimeout(startCountdown, 501);
}

/**
* Grab the days until the given date object and return. *Only works for up to a year away*
* @param {hackathonDate} hackathon date
* @return {daysTill} number of days until the hackathon date
*/
function getDaysTill(hackathonDate) {
    var currDate = new Date();
    var currMonth = currDate.getMonth()+1;
    var hackathonMonth = hackathonDate.getMonth()+1;

    //initialize days till with the days until the end of this month
    var daysTill = new Date(currDate.getFullYear(), currMonth, 0).getDate() - currDate.getDate();

    //increment month because we just added those days
    currMonth++;

    //While less than hackathon month, grab days in the month, add to total, increment currMonth
    while(currMonth < hackathonMonth) {
      daysInMonth = new Date(currDate.getFullYear(), currMonth, 0).getDate();
      daysTill += daysInMonth;
      currMonth++;
    }

    //Add the date inside the hackathon month to running total
    daysTill += hackathonDate.getDate();
    return daysTill;
}

//Trigger the countdown timer
startCountdown();

{'fraction_non_alphanumeric': 0.13185755534167468, 'fraction_numerical': 0.009865255052935515, 'mean_word_length': 2.885046728971963, 'pattern_counts': {'":': 0, '<': 33, '<?xml version=': 0, '>': 29, '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': '4462706', 'n_tokens_mistral': 1295, 'n_tokens_neox': 1266, 'n_words': 354}