Skip to content

Commit

Permalink
Merge pull request #16 from dvsa/opt-lock
Browse files Browse the repository at this point in the history
feat: github packages
  • Loading branch information
sr4850 authored Apr 30, 2024
2 parents 9f25c3d + 202ddd3 commit b0db183
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 21 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/maven-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,10 @@ jobs:
server-password: GITHUB_TOKEN_REF # env variable name for GitHub Personal Access Token

- name: Build with Maven
run: mvn -B package --file pom.xml
run: mvn -B -Pgithub package --file pom.xml

- name: Publish to GitHub Packages Apache Maven
run: mvn deploy -s $GITHUB_WORKSPACE/settings.xml
env:
GITHUB_USER_REF: ${{ secrets.GH_PACKAGE_REPO_USERNAME }}
GITHUB_TOKEN_REF: ${{ secrets.GH_PACKAGE_REPO_PASSWORD }}
GITHUB_TOKEN_REF: ${{ secrets.GH_PACKAGE_REPO_PASSWORD }}
42 changes: 23 additions & 19 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,10 @@
<groupId>org.dvsa.testing.framework</groupId>
<artifactId>vol-api-calls</artifactId>
<version>2.0.3</version>
<packaging>pom</packaging>

<properties>
<active-support.version>2.0.1.10</active-support.version>
<active-support.version>2.0.1.9</active-support.version>
<log4j.version>2.22.0</log4j.version>
<log4j12.version>2.22.0</log4j12.version>
<commons-lang3.version>3.14.0</commons-lang3.version>
Expand All @@ -19,6 +20,27 @@
<github.url>https://maven.pkg.github.com/dvsa/vol-api-calls</github.url>
</properties>

<profiles>
<profile>
<id>github</id>
<repositories>
<repository>
<id>central</id>
<url>https://repo1.maven.org/maven2</url>
<releases><enabled>true</enabled></releases>
<snapshots><enabled>true</enabled></snapshots>
</repository>
<repository>
<id>github</id>
<name>GitHub dvsa Apache Maven Packages</name>
<url>https://maven.pkg.github.com/dvsa/vol-active-support</url>
<snapshots><enabled>true</enabled></snapshots>
<releases><enabled>true</enabled></releases>
</repository>
</repositories>
</profile>
</profiles>

<build>
<extensions>
<extension>
Expand Down Expand Up @@ -73,24 +95,6 @@

</dependencies>

<repositories>
<repository>
<id>central</id>
<url>https://repo1.maven.org/maven2</url>
</repository>
<repository>
<id>vol-active-support</id>
<url>https://maven.pkg.github.com/dvsa/vol-active-support</url>
<snapshots>
<enabled>true</enabled>
</snapshots>
</repository>
<repository>
<id>github</id>
<name>GitHub dvsa Apache Maven Packages</name>
<url>${github.url}</url>
</repository>
</repositories>

<distributionManagement>
<repository>
Expand Down

0 comments on commit b0db183

Please sign in to comment.