Compare commits

..

No commits in common. "develop" and "v0.1.0" have entirely different histories.

51 changed files with 967 additions and 1300 deletions

View File

@ -9,8 +9,8 @@
----------
N: Robert Vokac
E: robertvokac@robertvokac.com
W: https://robertvokac.com
P: 4096R/C459E1E4 255C 69CC 1D09 CA54 EF0C C9DF FB9C E8E2 0AAD A55F
E: robertvokac@nanoboot.org
W: https://nanoboot.org
P: 4096R/E3329055 322B D109 0AA8 C324 EA9C 72F5 693D 30BE E332 9055
D: Founder
S: Czech Republic

114
Jenkinsfile vendored
View File

@ -1,114 +0,0 @@
pipeline
/*
DB Migration
Requirements:
Maven is Installed
Java 21 is installed - variable JAVA_21_HOME is set
*/
{
agent any
environment {
AAA = 'aaa'
}
stages
{
stage('Build')
{
steps {
echo "*** Building ${env.JOB_NAME} ***"
sh '''
#!/bin/bash
echo JOB_NAME=$JOB_NAME
if [ -z "$JAVA_21_HOME" ]
then
echo "KO : Variable JAVA_21_HOME is empty. You fix this issue by adding this variable to configuration of Jenkins."
exit 1
else
echo "OK : Variable JAVA_21_HOME is NOT empty"
fi
export JAVA_HOME=$JAVA_21_HOME
case $BRANCH_NAME in
master | deploy_prod)
mvn clean install
;;
develop | jenkins | deploy_test)
echo Branch $BRANCH_NAME is supported. Continuing.
version=`mvn help:evaluate -Dexpression=project.version -q -DforceStdout`
echo version=$version
case "$version" in
*"SNAPSHOT"*) echo echo version is OK ;;
* ) echo echo "You cannot build releases on Jenkins, only snapshots!"&&exit 1 ;;
esac
mvn clean deploy
;;
*)
echo Branch $BRANCH_NAME is not supported. A failure happened. Exiting.
exit 1
;;
esac
echo "Build of $JOB_NAME was successful"
'''
}
}
stage('Deploy')
{
steps {
echo "*** Deploying ${env.JOB_NAME} ***"
sh '''
#!/bin/bash
echo "Nothing to do"
exit
case $BRANCH_NAME in
master | deploy_prod)
echo Branch $BRANCH_NAME is supported. Continuing.
TOMCAT_HOME=$TOMCAT10_HOME
systemdService=tomcat10
;;
develop | jenkins | deploy_test)
echo Branch $BRANCH_NAME is supported. Continuing.
TOMCAT_HOME=$TOMCAT10_TEST_HOME
systemdService=tomcat10test
;;
*)
echo Branch $BRANCH_NAME is not supported. A failure happened. Exiting.
exit 1
;;
esac
'''
}
}
}
post {
always {
script {
env.color = "${currentBuild.currentResult == 'SUCCESS' ? 'green' : 'red'}"
}
echo 'Sending e-mail.'
sh "printenv | sort"
emailext body: "<b style=\"color:$COLOR\">${currentBuild.currentResult}</b> - ${env.JOB_NAME} (#${env.BUILD_NUMBER})<br> <ul style=\"margin-top:2px;padding-top:2px;padding-left:30px;\"><li>More info at: <a href=\"${env.BUILD_URL}\">${env.BUILD_URL}</a></li></ul>",
recipientProviders: [[$class: 'DevelopersRecipientProvider'], [$class: 'RequesterRecipientProvider']],
subject: "Jenkins Build - ${currentBuild.currentResult} - $JOB_NAME (#$BUILD_NUMBER)"
}
}
}

1090
LICENSE

File diff suppressed because it is too large Load Diff

View File

@ -23,12 +23,12 @@
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>com.robertvokac.tools.dbmigration</groupId>
<groupId>org.nanoboot.tools.dbmigration</groupId>
<artifactId>db-migration</artifactId>
<version>0.1.1-SNAPSHOT</version>
<version>0.1.0</version>
</parent>
<groupId>com.robertvokac.tools.dbmigration</groupId>
<groupId>org.nanoboot.tools.dbmigration</groupId>
<artifactId>db-migration-core</artifactId>
<packaging>jar</packaging>
@ -77,7 +77,7 @@
<configuration>
<archive>
<manifest>
<mainClass>com.robertvokac.dbmigration.core.main.DBMigration</mainClass>
<mainClass>org.nanoboot.dbmigration.core.main.DBMigration</mainClass>
</manifest>
</archive>
<descriptorRefs>
@ -132,11 +132,11 @@
</build>
<dependencies>
<!-- <dependency>
<dependency>
<groupId>org.flywaydb</groupId>
<artifactId>flyway-core</artifactId>
<version>${flyway-core.version}</version>
</dependency>-->
</dependency>
<!-- Lombok-->
<dependency>
<groupId>org.projectlombok</groupId>
@ -151,17 +151,17 @@
</dependency>
<!-- Power dependencies -->
<dependency>
<groupId>com.robertvokac.powerframework</groupId>
<groupId>org.nanoboot.powerframework</groupId>
<artifactId>power-time</artifactId>
<version>${power.version}</version>
</dependency>
<dependency>
<groupId>com.robertvokac.powerframework</groupId>
<groupId>org.nanoboot.powerframework</groupId>
<artifactId>power-core</artifactId>
<version>${power.version}</version>
</dependency>
<dependency>
<groupId>com.robertvokac.powerframework</groupId>
<groupId>org.nanoboot.powerframework</groupId>
<artifactId>power-security</artifactId>
<version>${power.version}</version>
</dependency>
@ -203,7 +203,7 @@
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.robertvokac.tools.dbmigration</groupId>
<groupId>org.nanoboot.tools.dbmigration</groupId>
<artifactId>db-migration-test-jar</artifactId>
<version>${dbmigration.version}</version>
<scope>test</scope>

View File

@ -1,44 +0,0 @@
///////////////////////////////////////////////////////////////////////////////////////////////
// db-migration: A database schema versioning tool.
// Copyright (C) 2021-2022 the original author or authors.
//
// This program is free software: you can redistribute it and/or
// modify it under the terms of the GNU General Public License
// as published by the Free Software Foundation, either version 3
// of the License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with this program. If not, see
// <https://www.gnu.org/licenses/> or write to the Free Software
// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
///////////////////////////////////////////////////////////////////////////////////////////////
package com.robertvokac.dbmigration.core.main;
import java.io.UnsupportedEncodingException;
/**
*
* @author <a href="mailto:robertvokac@robertvokac.com">Robert Vokac</a>
* @since 0.1.0
*/
public class DBMigrationException extends RuntimeException {
public DBMigrationException(String msg, Exception ex) {
super(msg, ex);
}
public DBMigrationException(String msg) {
super(msg);
}
public DBMigrationException(Exception ex) {
super(ex);
}
}

View File

@ -1,31 +0,0 @@
///////////////////////////////////////////////////////////////////////////////////////////////
// db-migration: A database schema versioning tool.
// Copyright (C) 2021-2022 the original author or authors.
//
// This program is free software: you can redistribute it and/or
// modify it under the terms of the GNU General Public License
// as published by the Free Software Foundation, either version 3
// of the License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with this program. If not, see
// <https://www.gnu.org/licenses/> or write to the Free Software
// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
///////////////////////////////////////////////////////////////////////////////////////////////
package com.robertvokac.dbmigration.core.main;
/**
*
* @author <a href="mailto:robertvokac@robertvokac.com">Robert Vokac</a>
* @since 0.1.0
*/
public enum MigrationResult {
SUCCESS, FAILURE;
}

View File

@ -1,30 +0,0 @@
///////////////////////////////////////////////////////////////////////////////////////////////
// db-migration: A database schema versioning tool.
// Copyright (C) 2021-2022 the original author or authors.
//
// This program is free software: you can redistribute it and/or
// modify it under the terms of the GNU General Public License
// as published by the Free Software Foundation, either version 3
// of the License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with this program. If not, see
// <https://www.gnu.org/licenses/> or write to the Free Software
// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
///////////////////////////////////////////////////////////////////////////////////////////////
package com.robertvokac.dbmigration.core.main;
/**
*
* @author <a href="mailto:robertvokac@robertvokac.com">Robert Vokac</a>
* @since 0.1.0
*/
public enum MigrationType {
SQL, JAVA;
}

View File

@ -1,30 +0,0 @@
///////////////////////////////////////////////////////////////////////////////////////////////
// db-migration: A database schema versioning tool.
// Copyright (C) 2021-2022 the original author or authors.
//
// This program is free software: you can redistribute it and/or
// modify it under the terms of the GNU General Public License
// as published by the Free Software Foundation, either version 3
// of the License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with this program. If not, see
// <https://www.gnu.org/licenses/> or write to the Free Software
// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
///////////////////////////////////////////////////////////////////////////////////////////////
package com.robertvokac.dbmigration.core.main;
/**
*
* @author <a href="mailto:robertvokac@robertvokac.com">Robert Vokac</a>
* @since 0.1.0
*/
public enum RepairResult {
SUCCESS, FAILURE;
}

View File

@ -1,30 +0,0 @@
///////////////////////////////////////////////////////////////////////////////////////////////
// db-migration: A database schema versioning tool.
// Copyright (C) 2021-2022 the original author or authors.
//
// This program is free software: you can redistribute it and/or
// modify it under the terms of the GNU General Public License
// as published by the Free Software Foundation, either version 3
// of the License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with this program. If not, see
// <https://www.gnu.org/licenses/> or write to the Free Software
// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
///////////////////////////////////////////////////////////////////////////////////////////////
package com.robertvokac.dbmigration.core.main;
/**
*
* @author <a href="mailto:robertvokac@robertvokac.com">Robert Vokac</a>
* @since 0.1.0
*/
public class SqlMigration {
}

View File

@ -1,38 +0,0 @@
///////////////////////////////////////////////////////////////////////////////////////////////
// db-migration: A database schema versioning tool.
// Copyright (C) 2021-2022 the original author or authors.
//
// This program is free software: you can redistribute it and/or
// modify it under the terms of the GNU General Public License
// as published by the Free Software Foundation, either version 3
// of the License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with this program. If not, see
// <https://www.gnu.org/licenses/> or write to the Free Software
// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
///////////////////////////////////////////////////////////////////////////////////////////////
package com.robertvokac.dbmigration.core.resources;
import java.util.List;
/**
*
* @author <a href="mailto:robertvokac@robertvokac.com">Robert Vokac</a>
* @since 0.1.0
*/
public interface SqlFileProvider {
List<SqlFile> provide(String path, Class<?> clazz);
default List<SqlFile> provide(String path) {
return provide(path, null);
}
}

View File

@ -19,11 +19,11 @@
/**
*
* @author <a href="mailto:robertvokac@robertvokac.com">Robert Vokac</a>
* @author <a href="mailto:robertvokac@nanoboot.org">Robert Vokac</a>
* @since 0.1.0
*/
module dbmigration.core {
//requires org.flywaydb.core;
requires org.flywaydb.core;
requires lombok;
requires java.sql;
requires powerframework.time;
@ -31,5 +31,5 @@ module dbmigration.core {
requires powerframework.security;
requires org.apache.logging.log4j;
requires org.apache.logging.log4j.core;
exports com.robertvokac.dbmigration.core.main;
exports org.nanoboot.dbmigration.core.main;
}

View File

@ -2,23 +2,22 @@
// db-migration: A database schema versioning tool.
// Copyright (C) 2021-2022 the original author or authors.
//
// This program is free software: you can redistribute it and/or
// modify it under the terms of the GNU General Public License
// as published by the Free Software Foundation, either version 3
// of the License, or (at your option) any later version.
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
// License as published by the Free Software Foundation;
// version 2.1 of the License only.
//
// This program is distributed in the hope that it will be useful,
// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with this program. If not, see
// <https://www.gnu.org/licenses/> or write to the Free Software
// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
// You should have received a copy of the GNU Lesser General Public
// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
///////////////////////////////////////////////////////////////////////////////////////////////
package com.robertvokac.dbmigration.core.configuration;
package org.nanoboot.dbmigration.core.configuration;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
@ -26,11 +25,11 @@ import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import com.robertvokac.dbmigration.core.main.DBMigrationException;
import org.nanoboot.dbmigration.core.main.DBMigrationException;
/**
*
* @author <a href="mailto:robertvokac@robertvokac.com">Robert Vokac</a>
* @author <a href="mailto:robertvokac@nanoboot.org">Robert Vokac</a>
* @since 0.1.0
*/
public class Configuration {

View File

@ -2,33 +2,32 @@
// db-migration: A database schema versioning tool.
// Copyright (C) 2021-2022 the original author or authors.
//
// This program is free software: you can redistribute it and/or
// modify it under the terms of the GNU General Public License
// as published by the Free Software Foundation, either version 3
// of the License, or (at your option) any later version.
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
// License as published by the Free Software Foundation;
// version 2.1 of the License only.
//
// This program is distributed in the hope that it will be useful,
// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with this program. If not, see
// <https://www.gnu.org/licenses/> or write to the Free Software
// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
// You should have received a copy of the GNU Lesser General Public
// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
///////////////////////////////////////////////////////////////////////////////////////////////
package com.robertvokac.dbmigration.core.configuration;
package org.nanoboot.dbmigration.core.configuration;
import lombok.AllArgsConstructor;
import lombok.Data;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import com.robertvokac.dbmigration.core.main.DBMigrationException;
import org.nanoboot.dbmigration.core.main.DBMigrationException;
/**
*
* @author <a href="mailto:robertvokac@robertvokac.com">Robert Vokac</a>
* @author <a href="mailto:robertvokac@nanoboot.org">Robert Vokac</a>
* @since 0.1.0
*/
@Data

View File

@ -2,27 +2,26 @@
// db-migration: A database schema versioning tool.
// Copyright (C) 2021-2022 the original author or authors.
//
// This program is free software: you can redistribute it and/or
// modify it under the terms of the GNU General Public License
// as published by the Free Software Foundation, either version 3
// of the License, or (at your option) any later version.
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
// License as published by the Free Software Foundation;
// version 2.1 of the License only.
//
// This program is distributed in the hope that it will be useful,
// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with this program. If not, see
// <https://www.gnu.org/licenses/> or write to the Free Software
// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
// You should have received a copy of the GNU Lesser General Public
// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
///////////////////////////////////////////////////////////////////////////////////////////////
package com.robertvokac.dbmigration.core.configuration;
package org.nanoboot.dbmigration.core.configuration;
/**
*
* @author <a href="mailto:robertvokac@robertvokac.com">Robert Vokac</a>
* @author <a href="mailto:robertvokac@nanoboot.org">Robert Vokac</a>
* @since 0.1.0
*/
public class ConfigurationKeys {

View File

@ -2,23 +2,22 @@
// db-migration: A database schema versioning tool.
// Copyright (C) 2021-2022 the original author or authors.
//
// This program is free software: you can redistribute it and/or
// modify it under the terms of the GNU General Public License
// as published by the Free Software Foundation, either version 3
// of the License, or (at your option) any later version.
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
// License as published by the Free Software Foundation;
// version 2.1 of the License only.
//
// This program is distributed in the hope that it will be useful,
// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with this program. If not, see
// <https://www.gnu.org/licenses/> or write to the Free Software
// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
// You should have received a copy of the GNU Lesser General Public
// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
///////////////////////////////////////////////////////////////////////////////////////////////
package com.robertvokac.dbmigration.core.entity;
package org.nanoboot.dbmigration.core.entity;
import java.io.UnsupportedEncodingException;
import java.security.NoSuchAlgorithmException;
@ -27,13 +26,13 @@ import lombok.Data;
import lombok.ToString;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import com.robertvokac.dbmigration.core.main.DBMigrationException;
import com.robertvokac.dbmigration.core.main.MigrationType;
import com.robertvokac.dbmigration.core.utils.DBMigrationUtils;
import org.nanoboot.dbmigration.core.main.DBMigrationException;
import org.nanoboot.dbmigration.core.main.MigrationType;
import org.nanoboot.dbmigration.core.utils.DBMigrationUtils;
/**
*
* @author <a href="mailto:robertvokac@robertvokac.com">Robert Vokac</a>
* @author <a href="mailto:robertvokac@nanoboot.org">Robert Vokac</a>
* @since 0.1.0
*/
@Data

View File

@ -2,23 +2,22 @@
// db-migration: A database schema versioning tool.
// Copyright (C) 2021-2022 the original author or authors.
//
// This program is free software: you can redistribute it and/or
// modify it under the terms of the GNU General Public License
// as published by the Free Software Foundation, either version 3
// of the License, or (at your option) any later version.
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
// License as published by the Free Software Foundation;
// version 2.1 of the License only.
//
// This program is distributed in the hope that it will be useful,
// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with this program. If not, see
// <https://www.gnu.org/licenses/> or write to the Free Software
// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
// You should have received a copy of the GNU Lesser General Public
// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
///////////////////////////////////////////////////////////////////////////////////////////////
package com.robertvokac.dbmigration.core.main;
package org.nanoboot.dbmigration.core.main;
import java.lang.reflect.Constructor;
import java.lang.reflect.InvocationTargetException;
@ -33,23 +32,23 @@ import java.util.UUID;
import java.util.logging.Level;
import java.util.logging.Logger;
import org.apache.logging.log4j.LogManager;
import com.robertvokac.dbmigration.core.configuration.Configuration;
import com.robertvokac.dbmigration.core.configuration.ConfigurationEntry;
import com.robertvokac.dbmigration.core.configuration.ConfigurationKeys;
import com.robertvokac.dbmigration.core.entity.DBMigrationSchemaHistory;
import com.robertvokac.dbmigration.core.resources.SqlFile;
import com.robertvokac.dbmigration.core.persistence.api.DBMigrationPersistence;
import com.robertvokac.dbmigration.core.query.DBMigrationSchemaHistoryTable;
import com.robertvokac.dbmigration.core.resources.FileSystemSqlFileProvider;
import com.robertvokac.dbmigration.core.resources.ResourcesSqlFileProvider;
import com.robertvokac.dbmigration.core.resources.SqlFileVersion;
import com.robertvokac.powerframework.time.duration.StopWatch;
import com.robertvokac.powerframework.time.moment.UniversalDateTime;
import com.robertvokac.powerframework.time.utils.TimeUnit;
import org.nanoboot.dbmigration.core.configuration.Configuration;
import org.nanoboot.dbmigration.core.configuration.ConfigurationEntry;
import org.nanoboot.dbmigration.core.configuration.ConfigurationKeys;
import org.nanoboot.dbmigration.core.entity.DBMigrationSchemaHistory;
import org.nanoboot.dbmigration.core.resources.SqlFile;
import org.nanoboot.dbmigration.core.persistence.api.DBMigrationPersistence;
import org.nanoboot.dbmigration.core.query.DBMigrationSchemaHistoryTable;
import org.nanoboot.dbmigration.core.resources.FileSystemSqlFileProvider;
import org.nanoboot.dbmigration.core.resources.ResourcesSqlFileProvider;
import org.nanoboot.dbmigration.core.resources.SqlFileVersion;
import org.nanoboot.powerframework.time.duration.StopWatch;
import org.nanoboot.powerframework.time.moment.UniversalDateTime;
import org.nanoboot.powerframework.time.utils.TimeUnit;
/**
*
* @author <a href="mailto:robertvokac@robertvokac.com">Robert Vokac</a>
* @author <a href="mailto:robertvokac@nanoboot.org">Robert Vokac</a>
* @since 0.1.0
*/
public class DBMigration {
@ -110,7 +109,7 @@ public class DBMigration {
private final Configuration configuration;
private final DBMigrationPersistence persistence;
//validate -datasource.jdbc-url=jdbc:sqlite:/home/robertvokac/Desktop/test.sqlite3 -name=testDev -sql-dialect=sqlite -sql-migrations-directory=/home/robertvokac/Desktop/testDev/ -installed-by=robertvokac -sql-dialect-impl-class=com.robertvokac.dbmigration.persistence.impl.sqlite.DBMigrationPersistenceSqliteImpl
//validate -datasource.jdbc-url=jdbc:sqlite:/home/robertvokac/Desktop/test.sqlite3 -name=testDev -sql-dialect=sqlite -sql-migrations-directory=/home/robertvokac/Desktop/testDev/ -installed-by=robertvokac -sql-dialect-impl-class=org.nanoboot.dbmigration.persistence.impl.sqlite.DBMigrationPersistenceSqliteImpl
public static void main(String[] args) {
LOG.info("*** DB Migration ***");
LOG.info("DB Migration main static method has just started.");
@ -133,11 +132,11 @@ public class DBMigration {
configuration.addAndAddPrefixIfNeeded(ConfigurationEntry.ofArgument(arg));
}
DBMigration dBMigration = new DBMigration(configuration);
//info -datasource.jdbc-url=jdbc:sqlite:/home/robertvokac/Desktop/test.sqlite3 -name=testDev -sql-dialect=sqlite -sql-migrations-directory=/home/robertvokac/Desktop/testDev/ -installed-by=robertvokac -sql-dialect-impl-class=com.robertvokac.dbmigration.core.persistence.impl.sqlite.DBMigrationPersistenceSqliteImpl
//info -datasource.jdbc-url=jdbc:sqlite:/home/robertvokac/Desktop/test.sqlite3 -name=testDev -sql-dialect=sqlite -sql-migrations-directory=/home/robertvokac/Desktop/testDev/ -installed-by=robertvokac -sql-dialect-impl-class=org.nanoboot.dbmigration.core.persistence.impl.sqlite.DBMigrationPersistenceSqliteImpl
// DBMigration dBMigration = DBMigration.configure()
// .dataSource("jdbc:sqlite:/home/robertvokac/Desktop/test.sqlite3")
// .name("testDev")
// .sqlDialect("sqlite", "com.robertvokac.dbmigration.persistence.impl.sqlite.DBMigrationPersistenceSqliteImpl")
// .sqlDialect("sqlite", "org.nanoboot.dbmigration.persistence.impl.sqlite.DBMigrationPersistenceSqliteImpl")
// .sqlMigrationsDirectory("/home/robertvokac/Desktop/testDev/")
// .installedBy("robertvokac")
// .load();

View File

@ -0,0 +1,43 @@
///////////////////////////////////////////////////////////////////////////////////////////////
// db-migration: A database schema versioning tool.
// Copyright (C) 2021-2022 the original author or authors.
//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
// License as published by the Free Software Foundation;
// version 2.1 of the License only.
//
// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
// You should have received a copy of the GNU Lesser General Public
// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
///////////////////////////////////////////////////////////////////////////////////////////////
package org.nanoboot.dbmigration.core.main;
import java.io.UnsupportedEncodingException;
/**
*
* @author <a href="mailto:robertvokac@nanoboot.org">Robert Vokac</a>
* @since 0.1.0
*/
public class DBMigrationException extends RuntimeException {
public DBMigrationException(String msg, Exception ex) {
super(msg, ex);
}
public DBMigrationException(String msg) {
super(msg);
}
public DBMigrationException(Exception ex) {
super(ex);
}
}

View File

@ -17,11 +17,11 @@
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
///////////////////////////////////////////////////////////////////////////////////////////////
package com.robertvokac.dbmigration.core.main;
package org.nanoboot.dbmigration.core.main;
/**
*
* @author <a href="mailto:robertvokac@robertvokac.com">Robert Vokac</a>
* @author <a href="mailto:robertvokac@nanoboot.org">Robert Vokac</a>
* @since 0.1.0
*/
public enum DBMigrationTarget {

View File

@ -0,0 +1,30 @@
///////////////////////////////////////////////////////////////////////////////////////////////
// db-migration: A database schema versioning tool.
// Copyright (C) 2021-2022 the original author or authors.
//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
// License as published by the Free Software Foundation;
// version 2.1 of the License only.
//
// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
// You should have received a copy of the GNU Lesser General Public
// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
///////////////////////////////////////////////////////////////////////////////////////////////
package org.nanoboot.dbmigration.core.main;
/**
*
* @author <a href="mailto:robertvokac@nanoboot.org">Robert Vokac</a>
* @since 0.1.0
*/
public enum MigrationResult {
SUCCESS, FAILURE;
}

View File

@ -0,0 +1,29 @@
///////////////////////////////////////////////////////////////////////////////////////////////
// db-migration: A database schema versioning tool.
// Copyright (C) 2021-2022 the original author or authors.
//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
// License as published by the Free Software Foundation;
// version 2.1 of the License only.
//
// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
// You should have received a copy of the GNU Lesser General Public
// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
///////////////////////////////////////////////////////////////////////////////////////////////
package org.nanoboot.dbmigration.core.main;
/**
*
* @author <a href="mailto:robertvokac@nanoboot.org">Robert Vokac</a>
* @since 0.1.0
*/
public enum MigrationType {
SQL, JAVA;
}

View File

@ -0,0 +1,29 @@
///////////////////////////////////////////////////////////////////////////////////////////////
// db-migration: A database schema versioning tool.
// Copyright (C) 2021-2022 the original author or authors.
//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
// License as published by the Free Software Foundation;
// version 2.1 of the License only.
//
// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
// You should have received a copy of the GNU Lesser General Public
// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
///////////////////////////////////////////////////////////////////////////////////////////////
package org.nanoboot.dbmigration.core.main;
/**
*
* @author <a href="mailto:robertvokac@nanoboot.org">Robert Vokac</a>
* @since 0.1.0
*/
public enum RepairResult {
SUCCESS, FAILURE;
}

View File

@ -0,0 +1,29 @@
///////////////////////////////////////////////////////////////////////////////////////////////
// db-migration: A database schema versioning tool.
// Copyright (C) 2021-2022 the original author or authors.
//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
// License as published by the Free Software Foundation;
// version 2.1 of the License only.
//
// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
// You should have received a copy of the GNU Lesser General Public
// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
///////////////////////////////////////////////////////////////////////////////////////////////
package org.nanoboot.dbmigration.core.main;
/**
*
* @author <a href="mailto:robertvokac@nanoboot.org">Robert Vokac</a>
* @since 0.1.0
*/
public class SqlMigration {
}

View File

@ -2,31 +2,30 @@
// db-migration: A database schema versioning tool.
// Copyright (C) 2021-2022 the original author or authors.
//
// This program is free software: you can redistribute it and/or
// modify it under the terms of the GNU General Public License
// as published by the Free Software Foundation, either version 3
// of the License, or (at your option) any later version.
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
// License as published by the Free Software Foundation;
// version 2.1 of the License only.
//
// This program is distributed in the hope that it will be useful,
// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with this program. If not, see
// <https://www.gnu.org/licenses/> or write to the Free Software
// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
// You should have received a copy of the GNU Lesser General Public
// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
///////////////////////////////////////////////////////////////////////////////////////////////
package com.robertvokac.dbmigration.core.persistence.api;
package org.nanoboot.dbmigration.core.persistence.api;
import java.util.List;
import com.robertvokac.dbmigration.core.configuration.Configuration;
import com.robertvokac.dbmigration.core.entity.DBMigrationSchemaHistory;
import org.nanoboot.dbmigration.core.configuration.Configuration;
import org.nanoboot.dbmigration.core.entity.DBMigrationSchemaHistory;
/**
*
* @author <a href="mailto:robertvokac@robertvokac.com">Robert Vokac</a>
* @author <a href="mailto:robertvokac@nanoboot.org">Robert Vokac</a>
* @since 0.1.0
*/
public interface DBMigrationPersistence {

View File

@ -2,23 +2,22 @@
// db-migration: A database schema versioning tool.
// Copyright (C) 2021-2022 the original author or authors.
//
// This program is free software: you can redistribute it and/or
// modify it under the terms of the GNU General Public License
// as published by the Free Software Foundation, either version 3
// of the License, or (at your option) any later version.
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
// License as published by the Free Software Foundation;
// version 2.1 of the License only.
//
// This program is distributed in the hope that it will be useful,
// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with this program. If not, see
// <https://www.gnu.org/licenses/> or write to the Free Software
// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
// You should have received a copy of the GNU Lesser General Public
// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
///////////////////////////////////////////////////////////////////////////////////////////////
package com.robertvokac.dbmigration.core.persistence.impl.base;
package org.nanoboot.dbmigration.core.persistence.impl.base;
import java.sql.Connection;
import java.sql.DriverManager;
@ -33,17 +32,17 @@ import java.util.UUID;
import java.util.logging.Level;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import com.robertvokac.dbmigration.core.configuration.Configuration;
import com.robertvokac.dbmigration.core.entity.DBMigrationSchemaHistory;
import com.robertvokac.dbmigration.core.main.DBMigrationException;
import com.robertvokac.dbmigration.core.main.MigrationType;
import com.robertvokac.dbmigration.core.persistence.api.DBMigrationPersistence;
import com.robertvokac.dbmigration.core.persistence.impl.sqlite.DBMigrationPersistenceSqliteImpl;
import com.robertvokac.dbmigration.core.query.DBMigrationSchemaHistoryTable;
import org.nanoboot.dbmigration.core.configuration.Configuration;
import org.nanoboot.dbmigration.core.entity.DBMigrationSchemaHistory;
import org.nanoboot.dbmigration.core.main.DBMigrationException;
import org.nanoboot.dbmigration.core.main.MigrationType;
import org.nanoboot.dbmigration.core.persistence.api.DBMigrationPersistence;
import org.nanoboot.dbmigration.core.persistence.impl.sqlite.DBMigrationPersistenceSqliteImpl;
import org.nanoboot.dbmigration.core.query.DBMigrationSchemaHistoryTable;
/**
*
* @author <a href="mailto:robertvokac@robertvokac.com">Robert Vokac</a>
* @author <a href="mailto:robertvokac@nanoboot.org">Robert Vokac</a>
* @since 0.1.0
*/
public abstract class DBMigrationPersistenceBase implements DBMigrationPersistence {

View File

@ -2,35 +2,34 @@
// db-migration: A database schema versioning tool.
// Copyright (C) 2021-2022 the original author or authors.
//
// This program is free software: you can redistribute it and/or
// modify it under the terms of the GNU General Public License
// as published by the Free Software Foundation, either version 3
// of the License, or (at your option) any later version.
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
// License as published by the Free Software Foundation;
// version 2.1 of the License only.
//
// This program is distributed in the hope that it will be useful,
// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with this program. If not, see
// <https://www.gnu.org/licenses/> or write to the Free Software
// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
// You should have received a copy of the GNU Lesser General Public
// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
///////////////////////////////////////////////////////////////////////////////////////////////
package com.robertvokac.dbmigration.core.persistence.impl.sqlite;
package org.nanoboot.dbmigration.core.persistence.impl.sqlite;
import java.sql.Connection;
import java.util.List;
import org.apache.logging.log4j.LogManager;
import com.robertvokac.dbmigration.core.entity.DBMigrationSchemaHistory;
import com.robertvokac.dbmigration.core.persistence.impl.base.DBMigrationPersistenceBase;
import com.robertvokac.dbmigration.core.query.DBMigrationSchemaHistoryTable;
import com.robertvokac.dbmigration.core.persistence.api.DBMigrationPersistence;
import org.nanoboot.dbmigration.core.entity.DBMigrationSchemaHistory;
import org.nanoboot.dbmigration.core.persistence.impl.base.DBMigrationPersistenceBase;
import org.nanoboot.dbmigration.core.query.DBMigrationSchemaHistoryTable;
import org.nanoboot.dbmigration.core.persistence.api.DBMigrationPersistence;
/**
*
* @author <a href="mailto:robertvokac@robertvokac.com">Robert Vokac</a>
* @author <a href="mailto:robertvokac@nanoboot.org">Robert Vokac</a>
* @since 0.1.0
*/
public class DBMigrationPersistenceSqliteImpl extends DBMigrationPersistenceBase implements DBMigrationPersistence {

View File

@ -2,27 +2,26 @@
// db-migration: A database schema versioning tool.
// Copyright (C) 2021-2022 the original author or authors.
//
// This program is free software: you can redistribute it and/or
// modify it under the terms of the GNU General Public License
// as published by the Free Software Foundation, either version 3
// of the License, or (at your option) any later version.
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
// License as published by the Free Software Foundation;
// version 2.1 of the License only.
//
// This program is distributed in the hope that it will be useful,
// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with this program. If not, see
// <https://www.gnu.org/licenses/> or write to the Free Software
// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
// You should have received a copy of the GNU Lesser General Public
// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
///////////////////////////////////////////////////////////////////////////////////////////////
package com.robertvokac.dbmigration.core.query;
package org.nanoboot.dbmigration.core.query;
/**
*
* @author <a href="mailto:robertvokac@robertvokac.com">Robert Vokac</a>
* @author <a href="mailto:robertvokac@nanoboot.org">Robert Vokac</a>
* @since 0.1.0
*/
public class DBMigrationSchemaHistoryTable {

View File

@ -2,35 +2,34 @@
// db-migration: A database schema versioning tool.
// Copyright (C) 2021-2022 the original author or authors.
//
// This program is free software: you can redistribute it and/or
// modify it under the terms of the GNU General Public License
// as published by the Free Software Foundation, either version 3
// of the License, or (at your option) any later version.
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
// License as published by the Free Software Foundation;
// version 2.1 of the License only.
//
// This program is distributed in the hope that it will be useful,
// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with this program. If not, see
// <https://www.gnu.org/licenses/> or write to the Free Software
// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
// You should have received a copy of the GNU Lesser General Public
// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
///////////////////////////////////////////////////////////////////////////////////////////////
package com.robertvokac.dbmigration.core.resources;
package org.nanoboot.dbmigration.core.resources;
import java.io.File;
import java.util.ArrayList;
import java.util.List;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import com.robertvokac.dbmigration.core.main.DBMigrationException;
import static com.robertvokac.dbmigration.core.utils.DBMigrationUtils.readTextFromFile;
import org.nanoboot.dbmigration.core.main.DBMigrationException;
import static org.nanoboot.dbmigration.core.utils.DBMigrationUtils.readTextFromFile;
/**
*
* @author <a href="mailto:robertvokac@robertvokac.com">Robert Vokac</a>
* @author <a href="mailto:robertvokac@nanoboot.org">Robert Vokac</a>
* @since 0.1.0
*/
public final class FileSystemSqlFileProvider implements SqlFileProvider {

View File

@ -2,23 +2,22 @@
// db-migration: A database schema versioning tool.
// Copyright (C) 2021-2022 the original author or authors.
//
// This program is free software: you can redistribute it and/or
// modify it under the terms of the GNU General Public License
// as published by the Free Software Foundation, either version 3
// of the License, or (at your option) any later version.
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
// License as published by the Free Software Foundation;
// version 2.1 of the License only.
//
// This program is distributed in the hope that it will be useful,
// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with this program. If not, see
// <https://www.gnu.org/licenses/> or write to the Free Software
// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
// You should have received a copy of the GNU Lesser General Public
// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
///////////////////////////////////////////////////////////////////////////////////////////////
package com.robertvokac.dbmigration.core.resources;
package org.nanoboot.dbmigration.core.resources;
import java.io.BufferedReader;
import java.io.File;
@ -38,12 +37,12 @@ import java.util.List;
import java.util.stream.Stream;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import com.robertvokac.dbmigration.core.main.DBMigrationException;
import com.robertvokac.dbmigration.core.utils.DBMigrationConstants;
import org.nanoboot.dbmigration.core.main.DBMigrationException;
import org.nanoboot.dbmigration.core.utils.DBMigrationConstants;
/**
*
* @author <a href="mailto:robertvokac@robertvokac.com">Robert Vokac</a>
* @author <a href="mailto:robertvokac@nanoboot.org">Robert Vokac</a>
* @since 0.1.0
*/
public final class ResourcesSqlFileProvider implements SqlFileProvider {

View File

@ -2,30 +2,29 @@
// db-migration: A database schema versioning tool.
// Copyright (C) 2021-2022 the original author or authors.
//
// This program is free software: you can redistribute it and/or
// modify it under the terms of the GNU General Public License
// as published by the Free Software Foundation, either version 3
// of the License, or (at your option) any later version.
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
// License as published by the Free Software Foundation;
// version 2.1 of the License only.
//
// This program is distributed in the hope that it will be useful,
// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with this program. If not, see
// <https://www.gnu.org/licenses/> or write to the Free Software
// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
// You should have received a copy of the GNU Lesser General Public
// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
///////////////////////////////////////////////////////////////////////////////////////////////
package com.robertvokac.dbmigration.core.resources;
package org.nanoboot.dbmigration.core.resources;
import lombok.Data;
import com.robertvokac.dbmigration.core.utils.DBMigrationUtils;
import org.nanoboot.dbmigration.core.utils.DBMigrationUtils;
/**
*
* @author <a href="mailto:robertvokac@robertvokac.com">Robert Vokac</a>
* @author <a href="mailto:robertvokac@nanoboot.org">Robert Vokac</a>
* @since 0.1.0
*/
@Data

View File

@ -2,35 +2,34 @@
// db-migration: A database schema versioning tool.
// Copyright (C) 2021-2022 the original author or authors.
//
// This program is free software: you can redistribute it and/or
// modify it under the terms of the GNU General Public License
// as published by the Free Software Foundation, either version 3
// of the License, or (at your option) any later version.
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
// License as published by the Free Software Foundation;
// version 2.1 of the License only.
//
// This program is distributed in the hope that it will be useful,
// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with this program. If not, see
// <https://www.gnu.org/licenses/> or write to the Free Software
// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
// You should have received a copy of the GNU Lesser General Public
// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
///////////////////////////////////////////////////////////////////////////////////////////////
package com.robertvokac.dbmigration.core.resources;
package org.nanoboot.dbmigration.core.resources;
import lombok.EqualsAndHashCode;
import lombok.Getter;
import lombok.ToString;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import com.robertvokac.dbmigration.core.main.DBMigrationException;
import com.robertvokac.dbmigration.core.utils.DBMigrationUtils;
import org.nanoboot.dbmigration.core.main.DBMigrationException;
import org.nanoboot.dbmigration.core.utils.DBMigrationUtils;
/**
*
* @author <a href="mailto:robertvokac@robertvokac.com">Robert Vokac</a>
* @author <a href="mailto:robertvokac@nanoboot.org">Robert Vokac</a>
* @since 0.1.0
*/
@EqualsAndHashCode

View File

@ -0,0 +1,37 @@
///////////////////////////////////////////////////////////////////////////////////////////////
// db-migration: A database schema versioning tool.
// Copyright (C) 2021-2022 the original author or authors.
//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
// License as published by the Free Software Foundation;
// version 2.1 of the License only.
//
// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
// You should have received a copy of the GNU Lesser General Public
// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
///////////////////////////////////////////////////////////////////////////////////////////////
package org.nanoboot.dbmigration.core.resources;
import java.util.List;
/**
*
* @author <a href="mailto:robertvokac@nanoboot.org">Robert Vokac</a>
* @since 0.1.0
*/
public interface SqlFileProvider {
List<SqlFile> provide(String path, Class<?> clazz);
default List<SqlFile> provide(String path) {
return provide(path, null);
}
}

View File

@ -2,23 +2,22 @@
// db-migration: A database schema versioning tool.
// Copyright (C) 2021-2022 the original author or authors.
//
// This program is free software: you can redistribute it and/or
// modify it under the terms of the GNU General Public License
// as published by the Free Software Foundation, either version 3
// of the License, or (at your option) any later version.
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
// License as published by the Free Software Foundation;
// version 2.1 of the License only.
//
// This program is distributed in the hope that it will be useful,
// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with this program. If not, see
// <https://www.gnu.org/licenses/> or write to the Free Software
// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
// You should have received a copy of the GNU Lesser General Public
// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
///////////////////////////////////////////////////////////////////////////////////////////////
package com.robertvokac.dbmigration.core.resources;
package org.nanoboot.dbmigration.core.resources;
import lombok.EqualsAndHashCode;
import lombok.Getter;
@ -27,7 +26,7 @@ import org.apache.logging.log4j.Logger;
/**
*
* @author <a href="mailto:robertvokac@robertvokac.com">Robert Vokac</a>
* @author <a href="mailto:robertvokac@nanoboot.org">Robert Vokac</a>
* @since 0.1.0
*/
@EqualsAndHashCode

View File

@ -17,11 +17,11 @@
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
///////////////////////////////////////////////////////////////////////////////////////////////
package com.robertvokac.dbmigration.core.utils;
package org.nanoboot.dbmigration.core.utils;
/**
*
* @author <a href="mailto:robertvokac@robertvokac.com">Robert Vokac</a>
* @author <a href="mailto:robertvokac@nanoboot.org">Robert Vokac</a>
* @since 0.1.0
*/
public class DBMigrationConstants {

View File

@ -17,7 +17,7 @@
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
///////////////////////////////////////////////////////////////////////////////////////////////
package com.robertvokac.dbmigration.core.utils;
package org.nanoboot.dbmigration.core.utils;
import java.io.BufferedReader;
import java.io.BufferedWriter;
@ -25,14 +25,14 @@ import java.io.FileReader;
import java.io.FileWriter;
import java.io.IOException;
import java.io.UnsupportedEncodingException;
import com.robertvokac.powerframework.security.hash.locator.HashCalculatorLocator;
import org.nanoboot.powerframework.security.hash.locator.HashCalculatorLocator;
import java.security.NoSuchAlgorithmException;
import com.robertvokac.dbmigration.core.main.DBMigrationException;
import com.robertvokac.powerframework.security.hash.locator.HashImpl;
import org.nanoboot.dbmigration.core.main.DBMigrationException;
import org.nanoboot.powerframework.security.hash.locator.HashImpl;
/**
*
* @author <a href="mailto:robertvokac@robertvokac.com">Robert Vokac</a>
* @author <a href="mailto:robertvokac@nanoboot.org">Robert Vokac</a>
* @since 0.1.0
*/
public class DBMigrationUtils {

View File

@ -17,7 +17,7 @@
</File>
</Appenders>
<Loggers>
<Logger name="com.robertvokac.dbmigration" level="debug" additivity="false">
<Logger name="org.nanoboot.dbmigration" level="debug" additivity="false">
<AppenderRef ref="File"/>
<AppenderRef ref="Console"/>
</Logger>

View File

@ -17,7 +17,7 @@
</File>
</Appenders>
<Loggers>
<Logger name="com.robertvokac.dbmigration" level="debug" additivity="false">
<Logger name="org.nanoboot.dbmigration" level="debug" additivity="false">
<AppenderRef ref="File"/>
<AppenderRef ref="Console"/>
</Logger>

View File

@ -17,9 +17,9 @@
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
///////////////////////////////////////////////////////////////////////////////////////////////
package com.robertvokac.dbmigration.core.configuration;
package org.nanoboot.dbmigration.core.configuration;
import com.robertvokac.dbmigration.core.main.DBMigrationException;
import org.nanoboot.dbmigration.core.main.DBMigrationException;
import org.junit.jupiter.api.AfterEach;
import org.junit.jupiter.api.AfterAll;
import org.junit.jupiter.api.BeforeEach;
@ -29,7 +29,7 @@ import static org.junit.jupiter.api.Assertions.*;
/**
*
* @author <a href="mailto:robertvokac@robertvokac.com">Robert Vokac</a>
* @author <a href="mailto:robertvokac@nanoboot.org">Robert Vokac</a>
* @since 0.1.0
*/
public class ConfigurationEntryTest {

View File

@ -17,11 +17,11 @@
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
///////////////////////////////////////////////////////////////////////////////////////////////
package com.robertvokac.dbmigration.core.configuration;
package org.nanoboot.dbmigration.core.configuration;
import java.util.ArrayList;
import java.util.List;
import com.robertvokac.dbmigration.core.main.DBMigrationException;
import org.nanoboot.dbmigration.core.main.DBMigrationException;
import org.junit.jupiter.api.AfterEach;
import org.junit.jupiter.api.AfterAll;
import org.junit.jupiter.api.BeforeEach;
@ -31,7 +31,7 @@ import static org.junit.jupiter.api.Assertions.*;
/**
*
* @author <a href="mailto:robertvokac@robertvokac.com">Robert Vokac</a>
* @author <a href="mailto:robertvokac@nanoboot.org">Robert Vokac</a>
* @since 0.1.0
*/
public class ConfigurationTest {

View File

@ -17,13 +17,13 @@
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
///////////////////////////////////////////////////////////////////////////////////////////////
package com.robertvokac.dbmigration.core.entity;
package org.nanoboot.dbmigration.core.entity;
import java.security.NoSuchAlgorithmException;
import java.util.logging.Level;
import java.util.logging.Logger;
import javax.net.ssl.KeyManagerFactory;
import com.robertvokac.dbmigration.core.main.DBMigrationException;
import org.nanoboot.dbmigration.core.main.DBMigrationException;
import org.junit.jupiter.api.AfterEach;
import org.junit.jupiter.api.AfterAll;
import org.junit.jupiter.api.BeforeEach;
@ -33,7 +33,7 @@ import static org.junit.jupiter.api.Assertions.*;
/**
*
* @author <a href="mailto:robertvokac@robertvokac.com">Robert Vokac</a>
* @author <a href="mailto:robertvokac@nanoboot.org">Robert Vokac</a>
* @since 0.1.0
*/
public class DBMigrationSchemaHistoryTest {

View File

@ -17,13 +17,13 @@
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
///////////////////////////////////////////////////////////////////////////////////////////////
package com.robertvokac.dbmigration.core.resources;
package org.nanoboot.dbmigration.core.resources;
import java.io.File;
import java.util.Collections;
import java.util.List;
import com.robertvokac.dbmigration.core.main.DBMigrationException;
import static com.robertvokac.dbmigration.core.utils.DBMigrationUtils.writeToFile;
import org.nanoboot.dbmigration.core.main.DBMigrationException;
import static org.nanoboot.dbmigration.core.utils.DBMigrationUtils.writeToFile;
import org.junit.jupiter.api.AfterEach;
import org.junit.jupiter.api.AfterAll;
import org.junit.jupiter.api.BeforeEach;
@ -33,7 +33,7 @@ import static org.junit.jupiter.api.Assertions.*;
/**
*
* @author <a href="mailto:robertvokac@robertvokac.com">Robert Vokac</a>
* @author <a href="mailto:robertvokac@nanoboot.org">Robert Vokac</a>
* @since 0.1.0
*/
public class FileSystemSqlFileProviderTest {

View File

@ -17,10 +17,10 @@
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
///////////////////////////////////////////////////////////////////////////////////////////////
package com.robertvokac.dbmigration.core.resources;
package org.nanoboot.dbmigration.core.resources;
import java.util.List;
import com.robertvokac.dbmigration.core.main.DBMigrationException;
import org.nanoboot.dbmigration.core.main.DBMigrationException;
import org.junit.jupiter.api.AfterEach;
import org.junit.jupiter.api.AfterAll;
import org.junit.jupiter.api.BeforeEach;
@ -30,7 +30,7 @@ import static org.junit.jupiter.api.Assertions.*;
/**
*
* @author <a href="mailto:robertvokac@robertvokac.com">Robert Vokac</a>
* @author <a href="mailto:robertvokac@nanoboot.org">Robert Vokac</a>
* @since 0.1.0
*/
public class ResourcesSqlFileProviderTest {
@ -95,7 +95,7 @@ public class ResourcesSqlFileProviderTest {
System.out.println("provide(String,Class)");
//prepare
String path = ResourcesSqlFileProvider.createPath("sqlite", "test");
Class clazz = com.robertvokac.dbmigration.test.jar.DBMigrationTestJarDummyClass.class;
Class clazz = org.nanoboot.dbmigration.test.jar.DBMigrationTestJarDummyClass.class;
ResourcesSqlFileProvider instance = new ResourcesSqlFileProvider();
List<SqlFile> expResult = null;
//execute

View File

@ -17,19 +17,19 @@
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
///////////////////////////////////////////////////////////////////////////////////////////////
package com.robertvokac.dbmigration.core.resources;
package org.nanoboot.dbmigration.core.resources;
import java.util.ArrayList;
import java.util.Collections;
import java.util.List;
import com.robertvokac.dbmigration.core.main.DBMigrationException;
import com.robertvokac.dbmigration.core.entity.DBMigrationSchemaHistory;
import org.nanoboot.dbmigration.core.main.DBMigrationException;
import org.nanoboot.dbmigration.core.entity.DBMigrationSchemaHistory;
import static org.junit.jupiter.api.Assertions.*;
import org.junit.jupiter.api.Test;
/**
*
* @author <a href="mailto:robertvokac@robertvokac.com">Robert Vokac</a>
* @author <a href="mailto:robertvokac@nanoboot.org">Robert Vokac</a>
* @since 0.1.0
*/
public class SqlFileNameTest {

View File

@ -17,7 +17,7 @@
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
///////////////////////////////////////////////////////////////////////////////////////////////
package com.robertvokac.dbmigration.core.resources;
package org.nanoboot.dbmigration.core.resources;
import java.util.List;
import lombok.Getter;
@ -30,7 +30,7 @@ import static org.junit.jupiter.api.Assertions.*;
/**
*
* @author <a href="mailto:robertvokac@robertvokac.com">Robert Vokac</a>
* @author <a href="mailto:robertvokac@nanoboot.org">Robert Vokac</a>
* @since 0.1.0
*/
public class SqlFileProviderTest {

View File

@ -17,9 +17,9 @@
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
///////////////////////////////////////////////////////////////////////////////////////////////
package com.robertvokac.dbmigration.core.resources;
package org.nanoboot.dbmigration.core.resources;
import com.robertvokac.dbmigration.core.main.DBMigrationException;
import org.nanoboot.dbmigration.core.main.DBMigrationException;
import org.junit.jupiter.api.AfterEach;
import org.junit.jupiter.api.AfterAll;
import org.junit.jupiter.api.BeforeEach;
@ -29,7 +29,7 @@ import static org.junit.jupiter.api.Assertions.*;
/**
*
* @author <a href="mailto:robertvokac@robertvokac.com">Robert Vokac</a>
* @author <a href="mailto:robertvokac@nanoboot.org">Robert Vokac</a>
* @since 0.1.0
*/
public class SqlFileTest {

View File

@ -17,7 +17,7 @@
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
///////////////////////////////////////////////////////////////////////////////////////////////
package com.robertvokac.dbmigration.core.utils;
package org.nanoboot.dbmigration.core.utils;
import java.lang.reflect.Constructor;
import java.lang.reflect.Modifier;
@ -31,7 +31,7 @@ import static org.junit.jupiter.api.Assertions.*;
/**
*
* @author <a href="mailto:robertvokac@robertvokac.com">Robert Vokac</a>
* @author <a href="mailto:robertvokac@nanoboot.org">Robert Vokac</a>
* @since 0.1.0
*/
public class DBMigrationUtilsTest {

View File

@ -23,12 +23,12 @@
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>com.robertvokac.tools.dbmigration</groupId>
<groupId>org.nanoboot.tools.dbmigration</groupId>
<artifactId>db-migration</artifactId>
<version>0.1.1-SNAPSHOT</version>
<version>0.1.0</version>
</parent>
<groupId>com.robertvokac.tools.dbmigration</groupId>
<groupId>org.nanoboot.tools.dbmigration</groupId>
<artifactId>db-migration-test-jar</artifactId>
<packaging>jar</packaging>
@ -153,17 +153,17 @@
</dependency>
<!-- Power dependencies -->
<dependency>
<groupId>com.robertvokac.powerframework</groupId>
<groupId>org.nanoboot.powerframework</groupId>
<artifactId>power-time</artifactId>
<version>${power.version}</version>
</dependency>
<dependency>
<groupId>com.robertvokac.powerframework</groupId>
<groupId>org.nanoboot.powerframework</groupId>
<artifactId>power-core</artifactId>
<version>${power.version}</version>
</dependency>
<dependency>
<groupId>com.robertvokac.powerframework</groupId>
<groupId>org.nanoboot.powerframework</groupId>
<artifactId>power-security</artifactId>
<version>${power.version}</version>
</dependency>

View File

@ -1,30 +0,0 @@
///////////////////////////////////////////////////////////////////////////////////////////////
// db-migration: A database schema versioning tool.
// Copyright (C) 2021-2022 the original author or authors.
//
// This program is free software: you can redistribute it and/or
// modify it under the terms of the GNU General Public License
// as published by the Free Software Foundation, either version 3
// of the License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with this program. If not, see
// <https://www.gnu.org/licenses/> or write to the Free Software
// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
///////////////////////////////////////////////////////////////////////////////////////////////
package com.robertvokac.dbmigration.test.jar;
/**
*
* @author <a href="mailto:robertvokac@robertvokac.com">Robert Vokac</a>
* @since 0.1.0
*/
public class DBMigrationTestJarDummyClass {
}

View File

@ -19,7 +19,7 @@
/**
*
* @author <a href="mailto:robertvokac@robertvokac.com">Robert Vokac</a>
* @author <a href="mailto:robertvokac@nanoboot.org">Robert Vokac</a>
* @since 0.1.0
*/
module dbmigration.testjar {
@ -31,5 +31,5 @@ module dbmigration.testjar {
requires powerframework.security;
requires org.apache.logging.log4j;
requires org.apache.logging.log4j.core;
exports com.robertvokac.dbmigration.test.jar;
exports org.nanoboot.dbmigration.test.jar;
}

View File

@ -0,0 +1,29 @@
///////////////////////////////////////////////////////////////////////////////////////////////
// db-migration: A database schema versioning tool.
// Copyright (C) 2021-2022 the original author or authors.
//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
// License as published by the Free Software Foundation;
// version 2.1 of the License only.
//
// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
// You should have received a copy of the GNU Lesser General Public
// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
///////////////////////////////////////////////////////////////////////////////////////////////
package org.nanoboot.dbmigration.test.jar;
/**
*
* @author <a href="mailto:robertvokac@nanoboot.org">Robert Vokac</a>
* @since 0.1.0
*/
public class DBMigrationTestJarDummyClass {
}

40
pom.xml
View File

@ -23,24 +23,24 @@
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>com.robertvokac.essential</groupId>
<artifactId>robertvokac-parent</artifactId>
<version>0.1.1-SNAPSHOT</version>
<groupId>org.nanoboot.essential</groupId>
<artifactId>nanoboot-parent</artifactId>
<version>0.1.0</version>
</parent>
<groupId>com.robertvokac.tools.dbmigration</groupId>
<groupId>org.nanoboot.tools.dbmigration</groupId>
<artifactId>db-migration</artifactId>
<version>0.1.1-SNAPSHOT</version>
<version>0.1.0</version>
<packaging>pom</packaging>
<name>DB Migration</name>
<description>Tool migrating databases versions.</description>
<properties>
<dbmigration.version>0.1.1-SNAPSHOT</dbmigration.version>
<dbmigration.version>0.1.0</dbmigration.version>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<checkstyle.skip>true</checkstyle.skip><!-- TODO: make false-->
<power.version>2.0.1-SNAPSHOT</power.version>
<power.version>2.0.0</power.version>
</properties>
<modules>
<module>db-migration-core</module>
@ -65,30 +65,4 @@
</dependencies>
<repositories>
<repository>
<id>robertvokac-releases-repository</id>
<name>robertvokac-releases-repository</name>
<url>https://maven.robertvokac.com/releases</url>
</repository>
<repository>
<id>robertvokac-snapshots-repository</id>
<name>robertvokac-snapshots-repository</name>
<url>https://maven.robertvokac.com/snapshots</url>
</repository>
</repositories>
<pluginRepositories>
<pluginRepository>
<id>robertvokac-releases-repository</id>
<name>robertvokac-releases-repository</name>
<url>https://maven.robertvokac.com/releases</url>
</pluginRepository>
<pluginRepository>
<id>robertvokac-snapshots-repository</id>
<name>robertvokac-snapshots-repository</name>
<url>https://maven.robertvokac.com/snapshots</url>
</pluginRepository>
</pluginRepositories>
</project>

View File

@ -3,13 +3,13 @@ cd ./db-migration-core/target&& \
java \
-cp "db-migration-core-0.0.0-SNAPSHOT-jar-with-dependencies.jar:../../db-migration-test-jar/target/db-migration-test-jar-0.0.0-SNAPSHOT.jar" \
--module-path "db-migration-core-0.0.0-SNAPSHOT-jar-with-dependencies.jar:../../db-migration-test-jar/target/db-migration-test-jar-0.0.0-SNAPSHOT.jar" \
com.robertvokac.dbmigration.core.main.DBMigration \
org.nanoboot.dbmigration.core.main.DBMigration \
migrate \
-datasource.jdbc-url=jdbc:sqlite:/home/robertvokac/Desktop/test.sqlite3 \
-name=test -sql-dialect=sqlite \
-sql-migrations-directory=/home/robertvokac/Desktop/testDev/ \
-installed-by=robertvokac \
-sql-dialect-impl-class=com.robertvokac.dbmigration.core.persistence.impl.sqlite.DBMigrationPersistenceSqliteImpl \
-sql-dialect-impl-class=org.nanoboot.dbmigration.core.persistence.impl.sqlite.DBMigrationPersistenceSqliteImpl \
&&cd ../..
#com.robertvokac.dbmigration.test.jar.DBMigrationTestJarDummyClass
#org.nanoboot.dbmigration.test.jar.DBMigrationTestJarDummyClass