diff --git a/Database/tools/CompileAuthenticationBase.sh b/Database/tools/CompileAuthenticationBase.sh new file mode 100644 index 000000000..0b6b47033 --- /dev/null +++ b/Database/tools/CompileAuthenticationBase.sh @@ -0,0 +1,6 @@ +#!/usr/bin/env bash +password=$( ../Base/AuthenticationBase.sql +echo >> ../Base/AuthenticationBase.sql +cat AuthenticationBase/*.sql >> ../Base/AuthenticationBase.sql diff --git a/Database/tools/DockerCompileAuthenticationBase.sh b/Database/tools/DockerCompileAuthenticationBase.sh new file mode 100644 index 000000000..0b6b47033 --- /dev/null +++ b/Database/tools/DockerCompileAuthenticationBase.sh @@ -0,0 +1,6 @@ +#!/usr/bin/env bash +password=$( ../Base/AuthenticationBase.sql +echo >> ../Base/AuthenticationBase.sql +cat AuthenticationBase/*.sql >> ../Base/AuthenticationBase.sql diff --git a/Database/tools/DockerExportShardBase.sh b/Database/tools/DockerExportShardBase.sh new file mode 100644 index 000000000..4355e711d --- /dev/null +++ b/Database/tools/DockerExportShardBase.sh @@ -0,0 +1,4 @@ +#!/usr/bin/env bash +password=$( ../Base/ShardBase.sql diff --git a/Database/tools/DockerExportWorldBase.sh b/Database/tools/DockerExportWorldBase.sh new file mode 100644 index 000000000..519f7fa57 --- /dev/null +++ b/Database/tools/DockerExportWorldBase.sh @@ -0,0 +1,4 @@ +#!/usr/bin/env bash +password=$( ../Base/WorldBase.sql diff --git a/Database/tools/ExportAuthenticationBase.sh b/Database/tools/ExportAuthenticationBase.sh new file mode 100644 index 000000000..c921b55d2 --- /dev/null +++ b/Database/tools/ExportAuthenticationBase.sh @@ -0,0 +1,4 @@ +#!/usr/bin/env bash +password=$( ../Base/AuthenticationBase.sql diff --git a/Database/tools/ExportShardBase.sh b/Database/tools/ExportShardBase.sh new file mode 100644 index 000000000..738fd9d0a --- /dev/null +++ b/Database/tools/ExportShardBase.sh @@ -0,0 +1,4 @@ +#!/usr/bin/env bash +password=$( ../Base/ShardBase.sql diff --git a/Database/tools/ExportWorldBase.sh b/Database/tools/ExportWorldBase.sh new file mode 100644 index 000000000..b0dc5f740 --- /dev/null +++ b/Database/tools/ExportWorldBase.sh @@ -0,0 +1,4 @@ +#!/usr/bin/env bash +password=$( ../Base/WorldBase.sql diff --git a/Database/tools/RebaseShardBase.sh b/Database/tools/RebaseShardBase.sh new file mode 100644 index 000000000..390b32ca5 --- /dev/null +++ b/Database/tools/RebaseShardBase.sh @@ -0,0 +1,11 @@ +#!/usr/bin/env bash +password=$( ../Base/ShardBase.sql diff --git a/Database/tools/RebaseWorldBase.sh b/Database/tools/RebaseWorldBase.sh new file mode 100644 index 000000000..599e45289 --- /dev/null +++ b/Database/tools/RebaseWorldBase.sh @@ -0,0 +1,11 @@ +#!/usr/bin/env bash +password=$( ../Base/WorldBase.sql diff --git a/README.md b/README.md index afeeafd31..8f57e86e8 100644 --- a/README.md +++ b/README.md @@ -39,3 +39,10 @@ Please note that this project is released with a [Contributor Code of Conduct](h ## Contact * [Discord Channel](https://discord.gg/C2WzhP9) + +## Database Management Scripts +Database export and rebase utilities are located in `Database/tools`. +Windows users can run the existing `*.bat` files, while Linux/macOS users can use +the new `*.sh` equivalents such as `ExportShardBase.sh` and +`RebaseWorldBase.sh`. These scripts call `mysqldump` and `mysql` from the +standard system paths.