<commit_before>package com.continuuity.gradle

/**
 *  Provides git functionality from Gradle.
 */
class GitRepo {

    private static File baseDir;

    /**
     * The name of the repo.
     */
    private String name;

    /**
     * The branch the repo should point to.
     */
    private String branch;

    /**
     * The URL where the repo was cloned from.
     */
    private String origin;

    /**
     * The directory location of the repo.
     */
    private String dir;

    /**
     * The shell to use to run git commands.
     */
    private String shell;

    /**
     * The options to pass to the shell.
     */
    private String shellOption;

    /**
     * @return  the directory path associated with the repo.
     */
    String getDirectory ()
    {
        init();
        return dir;
    }

    /**
     * Clones the repo if it doesn' already exist.
     */
    void load ()
    {
        init();
        File destination = new File(baseDir, dir);
        if(!destination.exists())
        {
            String cmd = "git clone -v --branch $branch $origin $destination.canonicalPath";
            println "$name: $cmd";
            runCommand(cmd);
        }
    }

    /**<commit_msg>adding extra verboseness for now to help troubleshoot CI build git failures<commit_after>package com.continuuity.gradle

/**
 *  Provides git functionality from Gradle.
 */
class GitRepo {

    private static File baseDir;

    /**
     * The name of the repo.
     */
    private String name;

    /**
     * The branch the repo should point to.
     */
    private String branch;

    /**
     * The URL where the repo was cloned from.
     */
    private String origin;

    /**
     * The directory location of the repo.
     */
    private String dir;

    /**
     * The shell to use to run git commands.
     */
    private String shell;

    /**
     * The options to pass to the shell.
     */
    private String shellOption;

    /**
     * @return  the directory path associated with the repo.
     */
    String getDirectory ()
    {
        init();
        return dir;
    }

    /**
     * Clones the repo if it doesn' already exist.
     */
    void load ()
    {
        init();
        File destination = new File(baseDir, dir);
        if(!destination.exists())
        {
            String cmd = "git clone -vv --branch $branch $origin $destination.canonicalPath";
            println "$name: $cmd";
            runCommand(cmd);
        }
    }

    /**
{'fraction_non_alphanumeric': 0.10399032648125756, 'fraction_numerical': 0.0, 'mean_word_length': 1.6460554371002132, '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': '6646213', 'n_tokens_mistral': 699, 'n_tokens_neox': 671, 'n_words': 241}