Skip to content

Commit

Permalink
Merge pull request #6 from rwth-acis/develop
Browse files Browse the repository at this point in the history
CI
  • Loading branch information
pdolif authored Jul 1, 2022
2 parents 3510b53 + 9d028a8 commit 5d7f154
Show file tree
Hide file tree
Showing 4 changed files with 72 additions and 0 deletions.
9 changes: 9 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
version: 2
updates:
- package-ecosystem: "gradle"
directory: "/lib"
target-branch: "develop"
schedule:
interval: "daily"
time: "09:00"
timezone: "Europe/Berlin"
26 changes: 26 additions & 0 deletions .github/workflows/gradle-publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: Publish package to GitHub Packages
on:
release:
types: [created]
jobs:
publish:
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
steps:
- uses: actions/checkout@v3
- uses: actions/setup-java@v3
with:
java-version: '17'
distribution: 'adopt'
- name: Grant execute permission for gradlew
run: chmod +x gradlew
- name: Validate Gradle wrapper
uses: gradle/wrapper-validation-action@e6e38bacfdf1a337459f332974bb2327a31aaf4b
- name: Publish package
uses: gradle/gradle-build-action@0d13054264b0bb894ded474f08ebb30921341cee
with:
arguments: publish
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
23 changes: 23 additions & 0 deletions .github/workflows/gradle.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: Java CI

on: [push]

jobs:
build:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3
- name: Set up JDK 17
uses: actions/setup-java@v3
with:
java-version: '17'
distribution: 'adopt'
- name: Grant execute permission for gradlew
run: chmod +x gradlew
- name: Validate Gradle wrapper
uses: gradle/wrapper-validation-action@e6e38bacfdf1a337459f332974bb2327a31aaf4b
- name: Build with Gradle
uses: gradle/gradle-build-action@0d13054264b0bb894ded474f08ebb30921341cee
with:
arguments: build
14 changes: 14 additions & 0 deletions lib/build.gradle
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
plugins {
// Apply the java-library plugin for API and implementation separation.
id 'java-library'
id 'maven-publish'
}

repositories {
Expand All @@ -15,3 +16,16 @@ dependencies {
implementation 'com.googlecode.json-simple:json-simple:1.1.1'
implementation 'javax.xml.bind:jaxb-api:2.3.1'
}

publishing {
repositories {
maven {
name = "GitHubPackages"
url = "https://maven.pkg.github.com/rwth-acis/las2peer-api-test-model"
credentials {
username = System.getenv("GITHUB_ACTOR")
password = System.getenv("GITHUB_TOKEN")
}
}
}
}

0 comments on commit 5d7f154

Please sign in to comment.