Make Workflow more generic

This commit is contained in:
Klemens Muthmann 2020-01-28 10:46:56 +01:00
parent 8a033e311c
commit aef31e0447
3 changed files with 8 additions and 4 deletions

View file

@ -1,6 +1,9 @@
name: Publish to Github Packages name: Publish to Github Packages
on: [push] on:
push:
branches:
- master
jobs: jobs:
build: build:
@ -19,5 +22,6 @@ jobs:
env: env:
GITHUB_USERNAME: x-access-token GITHUB_USERNAME: x-access-token
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GITHUB_REPOSITORY: ${{ github.repository }}
run: run:
mvn --settings settings.xml deploy -pl '!brouter-routing-app' mvn --settings settings.xml deploy -pl '!brouter-routing-app'

View file

@ -159,8 +159,8 @@
<distributionManagement> <distributionManagement>
<repository> <repository>
<id>github</id> <id>github</id>
<name>GitHub OWNER Apache Maven Packages</name> <name>GitHub brouter Apache Maven Packages</name>
<url>https://maven.pkg.github.com/cyface-de/brouter</url> <url>https://maven.pkg.github.com/${env.GITHUB_REPOSITORY}</url>
</repository> </repository>
</distributionManagement> </distributionManagement>
</project> </project>

View file

@ -23,7 +23,7 @@
<repository> <repository>
<id>github</id> <id>github</id>
<name>GitHub Cyface Apache Maven Packages</name> <name>GitHub Cyface Apache Maven Packages</name>
<url>https://maven.pkg.github.com/cyface-de/brouter</url> <url>https://maven.pkg.github.com/${env.GITHUB_REPOSITORY}</url>
</repository> </repository>
</repositories> </repositories>
</profile> </profile>