Skip to content
Snippets Groups Projects
Commit e4725be7 authored by René Schöne's avatar René Schöne
Browse files

Activate publishing on CI.

parent 2c0ba796
No related branches found
No related tags found
No related merge requests found
Pipeline #8595 passed
......@@ -4,9 +4,10 @@ variables:
stages:
- build
- test
- publish
build:
image: openjdk:8
image: openjdk:11
stage: build
before_script:
- ls -lah *
......@@ -14,10 +15,18 @@ build:
- ./gradlew assemble
test:
image: openjdk:8
image: openjdk:11
stage: test
script:
- ./gradlew test
artifacts:
reports:
junit: relast2uml.tests/build/test-results/test/TEST-*.xml
publish:
image: openjdk:11
stage: publish
script:
- "./gradlew publish"
only:
- master
plugins {
id 'java'
id 'idea'
id 'com.github.ben-manes.versions'
id 'maven-publish'
}
repositories {
mavenCentral()
}
dependencies {
testImplementation group: 'org.junit.jupiter', name: 'junit-jupiter-api', version: "${jupiter_version}"
testImplementation group: 'org.assertj', name: 'assertj-core', version: '3.18.1'
testRuntimeOnly group: 'org.junit.jupiter', name: 'junit-jupiter-engine', version: "${jupiter_version}"
}
tasks.named('test') {
useJUnitPlatform()
}
//679
publishing {
publications {
maven(MavenPublication) {
// artifactId = 'dumpAst | dumpAstWithPlantuml | grammar2uml'
groupId = 'de.tudresden.inf.st'
from components.java
// artifact("build/libs/ragconnect-${version}.jar") {
// extension 'jar'
// }
}
}
repositories {
maven {
url "https://git-st.inf.tu-dresden.de/api/v4/projects/679/packages/maven"
// Uncomment the following lines to publish manually (and comment out the other credentials section)
// credentials(HttpHeaderCredentials) {
// name = "Private-Token"
// value = gitLabPrivateToken // the variable resides in ~/.gradle/gradle.properties
// }
credentials(HttpHeaderCredentials) {
name = 'Job-Token'
value = System.getenv("CI_JOB_TOKEN")
}
authentication {
header(HttpHeaderAuthentication)
}
}
}
}
publish.dependsOn jar
......@@ -8,6 +8,7 @@ buildscript {
plugins {
id 'relast2uml.java-jastadd-conventions'
id 'relast2uml.java-publishing-conventions'
}
apply plugin: 'jastadd'
......
......@@ -8,6 +8,7 @@ buildscript {
plugins {
id 'relast2uml.java-jastadd-conventions'
id 'relast2uml.java-publishing-conventions'
}
apply plugin: 'jastadd'
......
......@@ -9,6 +9,7 @@ buildscript {
plugins {
id 'relast2uml.java-jastadd-conventions'
id 'relast2uml.java-application-conventions'
id 'relast2uml.java-publishing-conventions'
}
apply plugin: 'jastadd'
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment