better publishin messages

This commit is contained in:
gamma-delta 2022-11-13 12:07:19 -06:00
parent 7583adaa2e
commit c180f876ed
2 changed files with 6 additions and 2 deletions

5
Jenkinsfile vendored
View file

@ -23,7 +23,10 @@ pipeline {
}
}
stage('Publish') {
when { branch 'main' }
when { anyOf {
branch 'main'
branch '1.18'
} }
steps {
echo 'Deploying to Maven'
sh './gradlew publish sendWebhook'

View file

@ -207,7 +207,8 @@ task sendWebhook {
def message = new Message()
message.setUsername("Patreon Early Access")
message.setContent("New **$modName** release! Download it here: ${System.getenv("BUILD_URL")}\nChangelog:\n${getGitChangelog()}")
message.setContent("New **$modName** prerelease -- build ${System.getenv("BUILD_NUMBER")} for $minecraftVersion! \n" +
"Download it here: ${System.getenv("BUILD_URL")}\nChangelog:\n${getGitChangelog()}")
webhook.sendMessage(message)
} catch (ignored) {