-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge tag '2024.2.1' into pcheung/2024.2.1-jchem-23.4.0-commons-lang-…
…3.12
- Loading branch information
Showing
30 changed files
with
506 additions
and
146 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
# /bin/bash | ||
|
||
# Find all the flyway migration files and sort them in order of version number (semantically) | ||
# write them out as tab separated values with version\tfile | ||
|
||
java_files=$( find src/main/java/com/labsynch/labseer/db/migration -name "V*.java" ) | ||
|
||
# Loop through the files and get the version from the beginning of the file name | ||
# e.g. src/main/java/com/labsynch/labseer/db/migration/postgres/V1_0_6_6__copy_author_value_blob_values.java -> 1_0_6_6 | ||
all_versions="" | ||
for java_file in $java_files | ||
do | ||
file_name=$( basename $java_file ) | ||
version=$( echo $file_name | sed -e 's/V\([0-9_]*\)__.*/\1/' | sed -e 's/_/./g' ) | ||
# add java to the end of the version | ||
version="$version\t$java_file" | ||
all_versions="$all_versions $version" | ||
done | ||
|
||
# Get teh sql files in src/main/resources/db/migration/postgres | ||
sql_files=$( find src/main/resources/db/migration -name "*.sql" ) | ||
|
||
# Loop through the files and get the version from the beginning of the file name | ||
# e.g. src/main/resources/db/migration/postgres/V1_0_6_6__copy_author_value_blob_values.sql -> 1_0_6_6 | ||
for sql_file in $sql_files | ||
do | ||
file_name=$( basename $sql_file ) | ||
version=$( echo $file_name | sed -e 's/V\([0-9.]*\)__.*/\1/' ) | ||
version="$version\t$sql_file" | ||
all_versions="$all_versions $version" | ||
done | ||
|
||
|
||
# Do a semantically sorted list of the versions | ||
# Use printf to get the tabs to work | ||
printf "version\tfile" | ||
printf "$all_versions" | tr ' ' '\n' | sort -V | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.