# i don't know much about Jenkins pipeline but this is my first time and
here is what I did
//** pipeline to get the code from git branches and deploy to the staging
or production server **//
node {
def mvnHome
stage('Preparation') { // for display purposes
// Get some code from a GitHub repository
git 'https://github.com/jglick/simple-maven-project-with-tests.git'
// Get the Maven tool.
// ** NOTE: This 'M3' Maven tool must be configured
// ** in the global configuration.
}
stage('Execute commannds') {
//** Here you will aff the additional commands line npm
}
}
stage('deploy staging') {
ssh $user@IP 'cd $location && git status && git pll origin staging '\
}
}
if this is right Please guide me that how do I add the staging and
production branches accordingly and if i want to compile the code on the
way how do i do that . + how do i add secret variables in the jenkins that
i can use in the pipeline script
--
You received this message because you are subscribed to the Google Groups
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/jenkinsci-users/74eaf638-f1ba-4026-a67b-a2479da965e0%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.