This commit is contained in:
2021-06-09 09:37:18 +08:00

15
Jenkinsfile vendored
View File

@@ -4,15 +4,24 @@ pipeline {
stage('Build') { stage('Build') {
steps { steps {
echo 'StartBuild' echo 'StartBuild'
sh '''echo \'start build\'; sh 'dotnet restore Api/Ewide.Web.Entry/Ewide.Web.Entry.csproj'
''' sh 'dotnet clean Api/Ewide.Web.Entry/Ewide.Web.Entry.csproj'
writeFile(file: 'Api/Ewide.EntityFramework.Core/dbsettings.Development.json', text: '{}')
sh 'dotnet build Api/Ewide.Web.Entry/Ewide.Web.Entry.csproj'
} }
} }
stage('Test') { stage('Test') {
steps { steps {
echo 'Start Test' echo 'Start Test'
sh 'echo \'dotnet test\';' sh 'dotnet test Api/Ewide.Test/Ewide.Test.csproj'
}
}
stage('Publish') {
steps {
echo 'StartPublish'
sh 'dotnet publish Api/Ewide.Web.Entry/Ewide.Web.Entry.csproj -c Release'
} }
} }