Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 15 additions & 11 deletions Jenkinsfile
Original file line number Diff line number Diff line change
@@ -1,21 +1,25 @@
pipeline{
pipeline {
agent any

tools {
maven 'maven'
jdk 'java'
// Reference the Maven installation configured in Global Tool Configuration
maven 'Maven 3.9.11' // Use the name you gave your Maven installation
}

stages{
stage('checkout'){
steps{
checkout([$class: 'GitSCM', branches: [[name: '*/master']], extensions: [], userRemoteConfigs: [[credentialsId: 'github access', url: 'https://github.com/sreenivas449/java-hello-world-with-maven.git']]])
stages {
stage('Build') {
steps {
sh 'mvn clean install'
}
}
stage('build'){
steps{
bat 'mvn package'


stage('Test') {
steps {
sh 'mvn test'
}
}
}
}
}


6 changes: 3 additions & 3 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>org.springframework</groupId>
<artifactId>jb-hello-world-maven</artifactId>
<groupId>org.springfgitramework</groupId>
<artifactId>Daarmik-Manoj</artifactId>
<packaging>jar</packaging>
<version>0.2.0</version>
<version>2.0.0</version>

<!-- tag::joda[] -->
<properties>
Expand Down