Skip to content

Commit f6bdc30

Browse files
ddamkeddamke
authored andcommitted
add export script for Linux for KeepTime1.2.0
1 parent c577d71 commit f6bdc30

File tree

1 file changed

+27
-0
lines changed

1 file changed

+27
-0
lines changed
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
#!/bin/bash
2+
H2_VERSION=1.4.197
3+
DB_URL=jdbc:h2:file:./db/$H2_VERSION/keeptime-h2-db;DB_CLOSE_ON_EXIT=FALSE
4+
DB_USER=sa
5+
DB_PASSWD=
6+
SQL_BACKUP_FILENAME=KeepTime_database-export_H2-version-$H2_VERSION.sql
7+
8+
echo Get H2 jar from KeepTime jar ....
9+
jar xf keeptime-1.2.0-SNAPSHOT.jar
10+
rm -r org
11+
rm -r META-INF
12+
echo
13+
14+
DRIVER_JAR_FROM_KEEPTIME=BOOT-INF/lib/h2-$H2_VERSION.jar
15+
16+
echo Filename : $SQL_BACKUP_FILENAME
17+
echo
18+
echo Location :
19+
pwd
20+
echo
21+
22+
23+
java -cp $DRIVER_JAR_FROM_KEEPTIME org.h2.tools.Script -url $DB_URL -user $DB_USER -script $SQL_BACKUP_FILENAME -options DROP
24+
rm -r BOOT-INF
25+
26+
echo delete Files from unzipping KeepTime
27+
echo Export succeeded

0 commit comments

Comments
 (0)