Skip to content

Commit

Permalink
Merge branch 'webservice' into 'main'
Browse files Browse the repository at this point in the history
Webservice

See merge request Griefed/ServerPackCreator!560
  • Loading branch information
Griefed committed Dec 12, 2023
2 parents 9662ebf + be7f0df commit 82262d2
Show file tree
Hide file tree
Showing 7 changed files with 30 additions and 20 deletions.
8 changes: 4 additions & 4 deletions build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -42,12 +42,12 @@ allprojects {
}
evaluationDependsOnChildren()

project("serverpackcreator-web").tasks.getByName("build").mustRunAfter(
project("serverpackcreator-web-frontend").tasks.getByName("build")
project("serverpackcreator-web").tasks.build.get().mustRunAfter(
project("serverpackcreator-web-frontend").tasks.build.get()
)

project("serverpackcreator-app").tasks.getByName("build").mustRunAfter(
project("serverpackcreator-web").tasks.getByName("build")
project("serverpackcreator-app").tasks.build.get().mustRunAfter(
project("serverpackcreator-web").tasks.build.get()
)

nexusPublishing {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,13 @@ tasks.clean {
doFirst {
cleanup()
}
doLast {
delete {
fileTree(projectDir.resolve("src/main/resources/static")) {
exclude(".gitkeep")
}
}
}
}

tasks.test {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,11 +38,3 @@ tasks.getByName("installNode").finalizedBy(
tasks.getByName("installQuasar")
)

tasks.register("copyDist", Copy::class) {
from(projectDir.resolve("dist/spa"))
into(rootDir.resolve("serverpackcreator-web/src/main/resources/static"))
}

tasks.getByName("build").finalizedBy(
tasks.getByName("copyDist")
)
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,7 @@ class MigrationManager(
private val previous: String = apiProperties.oldVersion()
private val current: String = apiProperties.apiVersion
private val alphaBetaDev = ".*(alpha|beta|dev).*".toRegex()
private val release = "[0-9]+.[0-9]+.[0-9]+".toRegex()
val migrationMessages: MutableList<MigrationMessage> = ArrayList(10)

/**
Expand All @@ -92,19 +93,18 @@ class MigrationManager(
log.info("No migrations to execute. Upgrading from alpha, beta or dev version.")
return
}
if (isOlder(
previous, current
)
) {
if (!current.matches(release)) {
log.info("No migrations to execute. Running development branch.")
return
}
if (isOlder(previous, current)) {
log.info("No migrations to execute. User went back a version. From $previous to $current.")
return
}
if (previous == current) {
log.info("No migrations to execute. User has not updated.")
}
val migrationMethods = getMigrationMethods(
previous, current
)
val migrationMethods = getMigrationMethods(previous, current)
if (migrationMethods.isNotEmpty()) {
for (method in migrationMethods) {
log.info("Resolving migrations for: ${toSemantic(method!!.name)}")
Expand Down
12 changes: 11 additions & 1 deletion serverpackcreator-web-frontend/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,3 +1,13 @@
plugins {
id("serverpackcreator.quasar-conventions")
}
}

/*
tasks.register("copyDist", Copy::class) {
from(projectDir.resolve("dist/spa"))
into(rootDir.resolve("serverpackcreator-web/src/main/resources/static"))
}
tasks.build.get().finalizedBy(
tasks.getByName("copyDist")
)*/
1 change: 1 addition & 0 deletions serverpackcreator-web-frontend/quasar.conf.js
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,7 @@ module.exports = function (ctx) {
scopeHoisting: true,
vueRouterMode: 'hash', // available values: 'hash', 'history'
showProgress: true,
distDir: "../serverpackcreator-web/src/main/resources/static",
gzip: false,
analyze: false,
publicPath: '',
Expand Down
Empty file.

0 comments on commit 82262d2

Please sign in to comment.