-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
TASK-4017 the maven setup does now not contain the wrapper anymore
- Loading branch information
Showing
15 changed files
with
64 additions
and
50 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
name: Build | ||
on: | ||
push: | ||
branches: | ||
- '**' | ||
tags-ignore: | ||
- '**' | ||
|
||
jobs: | ||
build: | ||
name: Build | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v4 | ||
- name: Setup Java and Maven | ||
uses: actions/setup-java@v4 | ||
with: | ||
distribution: 'temurin' | ||
java-version: 17 | ||
cache: 'maven' | ||
server-id: 'ReLoAd' | ||
server-username: ${{ secrets.MAVEN_SERVER_USERNAME }} | ||
server-password: ${{ secrets.MAVEN_SERVER_PASSWORD }} | ||
- name: Build with Maven verify | ||
if: "github.ref != 'refs/heads/main'" | ||
run: ./mvnw -B verify | ||
- name: Build with Maven deploy | ||
if: "github.ref == 'refs/heads/main'" | ||
run: ./mvnw -B deploy |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,42 +1,29 @@ | ||
# MavenSetup | ||
A basic setup for all maven projects containing a build and tools for java. | ||
A basic setup for all maven projects containing building and tools for java. | ||
|
||
## Howto setup | ||
1. Execute the following command in the root directory of your project: | ||
```bash | ||
git submodule add --name MavenSetup [email protected]:ResilientGroup/MavenSetup.git .mvn | ||
# or if you have a fork under your namespace | ||
git submodule add --name MavenSetup ../MavenSetup.git .mvn | ||
``` | ||
2. Add the `branch = .` line to your .gitmodules file for the MavenSetup submodule. It should look like this: | ||
```properties | ||
[submodule="MavenSetup"] | ||
path = .mvn | ||
url = ../MavenSetup.git | ||
branch = . | ||
``` | ||
3. Add the following to your pom.xml: | ||
````xml | ||
<project> | ||
<parent> | ||
<groupId>works.reload</groupId> | ||
<artifactId>base</artifactId> | ||
<version>1.0.0</version> | ||
<relativePath>.mvn/Base/pom.xml</relativePath> | ||
</parent> | ||
1. Add the following to your pom.xml: | ||
````xml | ||
<project> | ||
<parent> | ||
<groupId>works.reload</groupId> | ||
<artifactId>base</artifactId> | ||
<version>1.0.0</version> | ||
<relativePath>.mvn/Base/pom.xml</relativePath> | ||
</parent> | ||
|
||
<!-- Only add this if you have a parent pom with packaging pom --> | ||
<modules> | ||
<module>.mvn/Base</module> | ||
<!-- Add your modules here --> | ||
</modules> | ||
</project> | ||
```` | ||
<repositories> | ||
<repository> | ||
<id>ReLoAd</id> | ||
<url>https://nexus.reloadkube.managedservices.resilient-teched.com/repository/reload/</url> | ||
</repository> | ||
</repositories> | ||
</project> | ||
```` | ||
|
||
## Maven Wrapper Note | ||
As this setup enforces a minimum maven version, | ||
it is not guaranteed that the maven version you have installed on your system is compatible with the project. | ||
For that, a maven wrapper is included in the setup. | ||
This means you can use the `.mvn/mvnw` command instead of `mvn` to execute maven commands. | ||
For that, a maven wrapper is recommended to be used. | ||
|
||
It is strongly recommended to use the wrapper in any automated build process, as it ensures that the correct maven version is used. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters