diff --git a/README.md b/README.md index f88d52f73..98cc4818f 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,4 @@ +[![Build Status](https://dev.azure.com/ikanyov/First%20Project/_apis/build/status%2FArcher743.azure-pipelines-java?branchName=main)](https://dev.azure.com/ikanyov/First%20Project/_build/latest?definitionId=1&branchName=main) # Contributing diff --git a/azure-pipelines.yml b/azure-pipelines.yml new file mode 100644 index 000000000..f7cbca04e --- /dev/null +++ b/azure-pipelines.yml @@ -0,0 +1,43 @@ +# Maven +# Build your Java project and run tests with Apache Maven. +# Add steps that analyze code, save build artifacts, deploy, and more: +# https://docs.microsoft.com/azure/devops/pipelines/languages/java + +variables: +- group: first-var-group + +trigger: +- main +- feature/* + +# Pull Requests targeting the main branch +pr: +- main + +pool: + vmImage: ubuntu-latest + +steps: +- bash: | + echo "Environment: $(env)" + echo "Password: $(password)" + +- task: Maven@4 + inputs: + mavenPomFile: 'pom.xml' + mavenOptions: '-Xmx3072m' + javaHomeOption: 'JDKVersion' + jdkVersionOption: '1.11' + jdkArchitectureOption: 'x64' + publishJUnitResults: true + testResultsFiles: '**/surefire-reports/TEST-*.xml' + goals: 'package' + +- script: | + mkdir -p $(Build.ArtifactStagingDirectory) + cp target/*.war $(Build.ArtifactStagingDirectory) + +- task: PublishPipelineArtifact@1 + inputs: + targetPath: '$(Build.ArtifactStagingDirectory)' + artifact: 'webapp' \ No newline at end of file diff --git a/test.txt b/test.txt new file mode 100644 index 000000000..e69de29bb