All checks were successful
Gitea/WheresMyMoney/pipeline/head This commit looks good
55 lines
2.0 KiB
Groovy
55 lines
2.0 KiB
Groovy
pipeline {
|
|
agent { label 'Kapitan-PC' }
|
|
environment {
|
|
ANDROID_HOME = 'C:\\Users\\lemi4\\AppData\\Local\\Android\\sdk'
|
|
DOTNET_ROOT = 'C:\\Program Files\\dotnet'
|
|
PATH = "${env.PATH};${env.ANDROID_HOME}\\tools;${env.ANDROID_HOME}\\platform-tools;${env.DOTNET_ROOT}"
|
|
ANDROID_SIGNING_PASSWORD = credentials('android-signing-password')
|
|
KEYSTORE = 'C:\\Projekty\\Keystore.keystore'
|
|
}
|
|
stages {
|
|
stage('Checkout') {
|
|
steps {
|
|
script {
|
|
checkout scm
|
|
}
|
|
}
|
|
}
|
|
stage('Restore Dependencies') {
|
|
steps {
|
|
script {
|
|
pwsh 'dotnet restore WheresMyMoney.sln'
|
|
}
|
|
}
|
|
}
|
|
stage('Build Android') {
|
|
steps {
|
|
script {
|
|
pwsh 'dotnet build WheresMyMoney.Maui\\WheresMyMoney.Maui.csproj -c Release -f net9.0-android'
|
|
}
|
|
}
|
|
}
|
|
stage('Build Windows') {
|
|
steps {
|
|
script {
|
|
pwsh 'dotnet build WheresMyMoney.Maui\\WheresMyMoney.Maui.csproj -c Release -f net9.0-windows10.0.19041.0'
|
|
}
|
|
}
|
|
}
|
|
stage('Publish Artifacts') {
|
|
steps {
|
|
script {
|
|
pwsh 'dotnet publish WheresMyMoney.Maui\\WheresMyMoney.Maui.csproj -c Release -f net9.0-android -p:AndroidKeyStore=true -p:AndroidSigningKeyStore=$env:KEYSTORE -p:AndroidSigningKeyAlias=WheresMyMoney -p:AndroidSigningKeyPass=env:ANDROID_SIGNING_PASSWORD -p:AndroidSigningStorePass=env:ANDROID_SIGNING_PASSWORD -o output\\android'
|
|
pwsh 'dotnet publish WheresMyMoney.Maui\\WheresMyMoney.Maui.csproj -c Release -f net9.0-windows10.0.19041.0 -o output\\windows'
|
|
}
|
|
archiveArtifacts artifacts: 'output/**/*', allowEmptyArchive: true
|
|
}
|
|
}
|
|
}
|
|
post {
|
|
always {
|
|
cleanWs()
|
|
}
|
|
}
|
|
}
|