diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 7b47377..4a93a61 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -58,10 +58,10 @@ jobs: sc start MySQL - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Setup JDK 11 - uses: actions/setup-java@v3 + uses: actions/setup-java@v4 with: distribution: 'adopt' java-version: '11' @@ -120,10 +120,10 @@ jobs: brew services restart mysql -v - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Setup JDK 11 - uses: actions/setup-java@v3 + uses: actions/setup-java@v4 with: distribution: 'adopt' java-version: '11' @@ -179,10 +179,10 @@ jobs: mysqladmin -u root -proot create mirai - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Setup JDK 11 - uses: actions/setup-java@v3 + uses: actions/setup-java@v4 with: distribution: 'adopt' java-version: '11' @@ -216,10 +216,10 @@ jobs: runs-on: ubuntu-latest steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Setup JDK 11 - uses: actions/setup-java@v3 + uses: actions/setup-java@v4 with: distribution: 'adopt' java-version: '11' @@ -231,7 +231,7 @@ jobs: run: ./gradlew buildPlugin - name: Upload - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: build-${{ github.run_id }} path: build/mirai/* \ No newline at end of file diff --git a/build.gradle.kts b/build.gradle.kts index b6fb302..d283e55 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -29,14 +29,14 @@ repositories { dependencies { api("com.zaxxer:HikariCP:5.1.0") api("com.h2database:h2:2.2.224") - api("org.xerial:sqlite-jdbc:3.45.1.0") + api("org.xerial:sqlite-jdbc:3.45.3.0") api("com.mysql:mysql-connector-j:8.3.0") api("org.mariadb.jdbc:mariadb-java-client:3.3.3") - api("org.postgresql:postgresql:42.7.2") + api("org.postgresql:postgresql:42.7.3") api("org.reflections:reflections:0.10.2") compileOnly("xyz.cssxsh.mirai:mirai-administrator:1.4.0") testImplementation(kotlin("test")) - testImplementation("com.microsoft.sqlserver:mssql-jdbc:12.6.1.jre11") + testImplementation("com.microsoft.sqlserver:mssql-jdbc:12.7.0") // implementation(platform("net.mamoe:mirai-bom:2.16.0")) compileOnly("net.mamoe:mirai-core") @@ -51,7 +51,7 @@ dependencies { api("org.hibernate.orm:hibernate-hikaricp") api("org.hibernate.orm:hibernate-community-dialects") // - implementation(platform("org.slf4j:slf4j-parent:2.0.12")) + implementation(platform("org.slf4j:slf4j-parent:2.0.13")) testImplementation("org.slf4j:slf4j-simple") } diff --git a/src/main/kotlin/xyz/cssxsh/mirai/hibernate/MiraiHibernateUtils.kt b/src/main/kotlin/xyz/cssxsh/mirai/hibernate/MiraiHibernateUtils.kt index 7f4cfc1..6e75d48 100644 --- a/src/main/kotlin/xyz/cssxsh/mirai/hibernate/MiraiHibernateUtils.kt +++ b/src/main/kotlin/xyz/cssxsh/mirai/hibernate/MiraiHibernateUtils.kt @@ -54,17 +54,16 @@ public fun dialects(): Set> { /** * 获取 MSSQL 驱动 artifact id - * - * version by Property xyz.cssxsh.mirai.hibernate.mssql.version */ @PublishedApi internal fun mssql(): String { val java = System.getProperty("java.version") // val version = System.getProperty("xyz.cssxsh.mirai.hibernate.mssql.version", "11.2.3") return when { - java.startsWith("17") -> "com.microsoft.sqlserver:mssql-jdbc:12.6.1.jre11" - java.startsWith("11") -> "com.microsoft.sqlserver:mssql-jdbc:12.6.1.jre11" - else -> "com.microsoft.sqlserver:mssql-jdbc:12.4.2.jre8" + java.startsWith("17") -> "com.microsoft.sqlserver:mssql-jdbc:12.7.0.jre11-preview" + java.startsWith("11") -> "com.microsoft.sqlserver:mssql-jdbc:12.7.0.jre11-preview" + java.startsWith("8") -> "com.microsoft.sqlserver:mssql-jdbc:12.7.0.jre8-preview" + else -> "com.microsoft.sqlserver:mssql-jdbc:12.7.0" } }