Skip to content

Commit

Permalink
Deploy PDE artifacts to maven
Browse files Browse the repository at this point in the history
  • Loading branch information
laeubi committed Nov 28, 2023
1 parent 3a696fb commit 0ddb87f
Show file tree
Hide file tree
Showing 2 changed files with 35 additions and 1 deletion.
14 changes: 13 additions & 1 deletion Jenkinsfile
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
def deployBranch = 'master'

pipeline {
options {
timeout(time: 40, unit: 'MINUTES')
Expand All @@ -12,12 +14,15 @@ pipeline {
maven 'apache-maven-latest'
jdk 'temurin-jdk17-latest'
}
environment {
MVN_GOALS = getMavenGoals()
}
stages {
stage('Build') {
steps {
wrap([$class: 'Xvnc', useXauthority: true]) {
sh '''
mvn clean verify --batch-mode -Dmaven.repo.local=$WORKSPACE/.m2/repository \
mvn clean ${MVN_GOALS} --batch-mode -Dmaven.repo.local=$WORKSPACE/.m2/repository \
-Pbree-libs \
-Papi-check \
-Pjavadoc \
Expand All @@ -39,3 +44,10 @@ pipeline {
}
}
}

def getMavenGoals() {
//if(env.BRANCH_NAME == deployBranch) {
return "deploy -DdeployAtEnd=true"
//}
// return "verify"
}
22 changes: 22 additions & 0 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,19 @@
<module>features</module>
<module>org.eclipse.pde.doc.user</module>
</modules>

<distributionManagement>
<repository>
<id>repo.eclipse.org</id>
<name>PDE - Releases</name>
<url>https://repo.eclipse.org/content/repositories/pde/</url>
</repository>
<snapshotRepository>
<id>repo.eclipse.org</id>
<name>PDE - Snapshots</name>
<url>https://repo.eclipse.org/content/repositories/pde-snapshots/</url>
</snapshotRepository>
</distributionManagement>

<!--
To build individual bundles, we specify a repository where to find parent pom,
Expand Down Expand Up @@ -103,7 +116,16 @@
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-deploy-plugin</artifactId>
<version>3.1.1</version>
</plugin>
</plugins>
<pluginManagement>
<plugins>
</plugins>
</pluginManagement>
</build>
</profile>
</profiles>
Expand Down

0 comments on commit 0ddb87f

Please sign in to comment.