<commit_before>package org.javalite.db_migrator.maven;

import org.apache.maven.plugin.MojoExecutionException;
import org.apache.maven.plugins.annotations.Mojo;


@Mojo(name = "reset")
public class ResetMojo extends AbstractDbMigrationMojo {
    public void executeMojo() throws MojoExecutionException {
        getLog().info("Resetting database " + getUrl());

        try {
            DropMojo dropMojo = new DropMojo();
            set(dropMojo);
            CreateMojo createMojo = new CreateMojo();
            set(createMojo);
            MigrateMojo migrateMojo = new MigrateMojo();
            set(migrateMojo);

            dropMojo.executeMojo();
            createMojo.executeMojo();
            migrateMojo.executeMojo();
        } catch (MojoExecutionException e) {
            throw new MojoExecutionException("Failed to reset database " + getUrl(), e);
        }
    }

    private void set(AbstractDbMigrationMojo mojo) {
        mojo.setLog(getLog());
        mojo.setUrl(getUrl());
        mojo.setUsername(getUsername());<commit_msg>#1129 - db-migrator:reset doesn't work with a groove migration<commit_after>package org.javalite.db_migrator.maven;

import org.apache.maven.plugin.MojoExecutionException;
import org.apache.maven.plugins.annotations.Mojo;
import org.apache.maven.plugins.annotations.ResolutionScope;


@Mojo(name = "reset", requiresDependencyResolution = ResolutionScope.COMPILE_PLUS_RUNTIME)
public class ResetMojo extends AbstractDbMigrationMojo {
    public void executeMojo() throws MojoExecutionException {
        getLog().info("Resetting database " + getUrl());

        try {
            DropMojo dropMojo = new DropMojo();
            set(dropMojo);
            CreateMojo createMojo = new CreateMojo();
            set(createMojo);
            MigrateMojo migrateMojo = new MigrateMojo();
            set(migrateMojo);

            dropMojo.executeMojo();
            createMojo.executeMojo();
            migrateMojo.executeMojo();
        } catch (MojoExecutionException e) {
            throw new MojoExecutionException("Failed to reset database " + getUrl(), e);
        }
    }

    private void set(AbstractDbMigrationMojo mojo) {
        mojo.setLog(getLog());
        mojo.setUrl(getUrl());
        mojo.setUsername(getUsername());
{'fraction_non_alphanumeric': 0.10153172866520788, 'fraction_numerical': 0.00175054704595186, 'mean_word_length': 2.8484848484848486, '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': '5664349', 'n_tokens_mistral': 668, 'n_tokens_neox': 655, 'n_words': 126}