generated from lengors/maven-java-template
-
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit 87e6467
Showing
27 changed files
with
1,625 additions
and
0 deletions.
There are no files selected for viewing
Validating CODEOWNERS rules …
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,3 @@ | ||
# Default code owners | ||
|
||
* @lengors |
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,2 @@ | ||
--- | ||
patreon: lengors |
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,45 @@ | ||
--- | ||
name: Bug report | ||
description: Report a bug | ||
labels: | ||
- bug | ||
body: | ||
- type: markdown | ||
attributes: | ||
value: ⚠️ Make sure to search for existing issues, discussions or pull requests before creating a new issue. | ||
- type: textarea | ||
attributes: | ||
label: Current behavior | ||
description: A clear and concise description of what the bug is. | ||
validations: | ||
required: true | ||
- type: textarea | ||
attributes: | ||
label: Expected behavior | ||
description: A clear and concise description of what you expected to happen. | ||
validations: | ||
required: true | ||
- type: textarea | ||
attributes: | ||
label: Steps to reproduce | ||
description: Steps to reproduce the behavior. | ||
validations: | ||
required: true | ||
- type: textarea | ||
attributes: | ||
label: Screenshots | ||
description: If applicable, add screenshots to help explain your problem. | ||
validations: | ||
required: false | ||
- type: textarea | ||
attributes: | ||
label: Additional context | ||
description: Add any other context about the problem here. | ||
validations: | ||
required: false | ||
- type: textarea | ||
attributes: | ||
label: Related issues, discussions or pull requests | ||
description: Link to related issues, discussions or pull requests. | ||
validations: | ||
required: false |
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,12 @@ | ||
--- | ||
blank_issues_enabled: false | ||
contact_links: | ||
- name: General | ||
url: https://github.com/lengors/java-template/discussions/new?category=general | ||
about: Chat about anything and everything here | ||
- name: Ideas | ||
url: https://github.com/lengors/java-template/discussions/new?category=ideas | ||
about: Share ideas for new features | ||
- name: Questions | ||
url: https://github.com/lengors/java-template/discussions/new?category=q-a | ||
about: Ask the community for help |
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: Create task | ||
description: Create a task | ||
body: | ||
- type: markdown | ||
attributes: | ||
value: ⚠️ Make sure to search for existing issues, discussions or pull requests before creating a new issue. | ||
- type: textarea | ||
attributes: | ||
label: Description | ||
description: A clear and concise description of what the chore is. | ||
validations: | ||
required: true | ||
- type: textarea | ||
attributes: | ||
label: Screenshots | ||
description: If applicable, add screenshots to help explain your problem. | ||
validations: | ||
required: false | ||
- type: textarea | ||
attributes: | ||
label: Additional context | ||
description: Add any other context about the chore here. | ||
validations: | ||
required: false | ||
- type: textarea | ||
attributes: | ||
label: Related issues, discussions or pull requests | ||
description: Link to related issues, discussions or pull requests. | ||
validations: | ||
required: false |
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,45 @@ | ||
--- | ||
name: Feature request | ||
description: Request a new feature | ||
labels: | ||
- enhancement | ||
body: | ||
- type: markdown | ||
attributes: | ||
value: ⚠️ Make sure to search for existing issues, discussions or pull requests before creating a new issue. | ||
- type: textarea | ||
attributes: | ||
label: Description | ||
description: A clear and concise description of what the problem is. Ex. I'm always frustrated when [...] | ||
validations: | ||
required: true | ||
- type: textarea | ||
attributes: | ||
label: Proposed solution | ||
description: A clear and concise description of what you want to happen. | ||
validations: | ||
required: true | ||
- type: textarea | ||
attributes: | ||
label: Alternatives considered | ||
description: A clear and concise description of any alternative solutions or features you've considered. | ||
validations: | ||
required: false | ||
- type: textarea | ||
attributes: | ||
label: Screenshots | ||
description: If applicable, add screenshots to help explain your problem or suggestion. | ||
validations: | ||
required: false | ||
- type: textarea | ||
attributes: | ||
label: Additional context | ||
description: Add any other context about the problem here. | ||
validations: | ||
required: false | ||
- type: textarea | ||
attributes: | ||
label: Related issues, discussions or pull requests | ||
description: Link to related issues, discussions or pull requests. | ||
validations: | ||
required: false |
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,17 @@ | ||
<!-- | ||
Thank you for your contribution to the Maven Java Template! We appreciate your efforts. | ||
Before submitting your pull request, please ensure you've covered the following: | ||
1. **Branching**: Create your branch from a fork of the repository and base it on the `dev` branch. | ||
2. **PR Title**: | ||
- Use the default title: "🔀 Merge `origin/<source_branch>` into `origin/<target_branch:usually dev>`". | ||
- If your PR addresses an issue, link the issue number in the `Development` section of the PR body. | ||
- If your PR does not address an issue, include a brief description in the PR body detailing the purpose and scope of the changes. | ||
3. **Testing**: Run `./mvnw clean test` to ensure all tests pass. | ||
4. **Code Style**: Check your code with [Checkstyle](https://checkstyle.org) (`./mvnw checkstyle:check`). | ||
When merging the PR, please use the default title, and include the issue reference `#issue_number` in parentheses after the title if applicable and missing. | ||
For more details on contributing, please refer to our guide: https://github.com/lengors/maven-java-template/blob/main/CONTRIBUTING.md | ||
--> |
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,61 @@ | ||
--- | ||
name: Publish package to maven central | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
- beta | ||
- alpha | ||
- dev | ||
|
||
jobs: | ||
deploy-and-publish: | ||
name: Deploy and publish package | ||
runs-on: ubuntu-latest | ||
environment: deployment | ||
steps: | ||
- name: Create GitHub app token | ||
uses: actions/create-github-app-token@v1 | ||
id: app-token | ||
with: | ||
app-id: ${{ secrets.GH_APP_ID }} | ||
private-key: ${{ secrets.GH_PRIVATE_KEY }} | ||
- name: Checkout repository | ||
uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
token: ${{ steps.app-token.outputs.token }} | ||
persist-credentials: false | ||
- name: Import GPG key | ||
id: import-gpg | ||
uses: crazy-max/ghaction-import-gpg@v6 | ||
with: | ||
gpg_private_key: ${{ secrets.GPG_PRIVATE_KEY }} | ||
passphrase: ${{ secrets.GPG_PASSPHRASE }} | ||
git_user_signingkey: true | ||
git_commit_gpgsign: true | ||
- name: Setup JDK 21 | ||
uses: actions/setup-java@v4 | ||
with: | ||
java-version: "21" | ||
distribution: temurin | ||
cache: maven | ||
gpg-private-key: ${{ secrets.GPG_PRIVATE_KEY }} | ||
gpg-passphrase: ${{ secrets.GPG_PASSPHRASE }} | ||
- name: Publish package | ||
id: semantic | ||
uses: cycjimmy/semantic-release-action@v4 | ||
with: | ||
extra_plugins: | | ||
@semantic-release/exec | ||
semantic-release-gitmoji | ||
env: | ||
GITHUB_TOKEN: ${{ steps.app-token.outputs.token }} | ||
GIT_AUTHOR_NAME: ${{ steps.import-gpg.outputs.name }} | ||
GIT_AUTHOR_EMAIL: ${{ steps.import-gpg.outputs.email }} | ||
GIT_COMMITTER_NAME: ${{ steps.import-gpg.outputs.name }} | ||
GIT_COMMITTER_EMAIL: ${{ steps.import-gpg.outputs.email }} | ||
MAVEN_GPG_PASSPHRASE: ${{ secrets.GPG_PASSPHRASE }} | ||
MAVEN_CENTRAL_USERNAME: ${{ secrets.MAVEN_CENTRAL_USERNAME }} | ||
MAVEN_CENTRAL_PASSWORD: ${{ secrets.MAVEN_CENTRAL_PASSWORD }} |
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,38 @@ | ||
--- | ||
name: Static code analysis | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
- beta | ||
- alpha | ||
- dev | ||
pull_request: | ||
branches: | ||
- main | ||
- beta | ||
- alpha | ||
- dev | ||
|
||
jobs: | ||
code-analysis: | ||
name: Static code analysis | ||
environment: code-analysis | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
- name: Setup JDK 21 | ||
uses: actions/setup-java@v4 | ||
with: | ||
java-version: "21" | ||
distribution: "temurin" | ||
cache: maven | ||
- name: Perform static code analysis | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} | ||
run: ./mvnw -B verify org.sonarsource.scanner.maven:sonar-maven-plugin:sonar -Dgpg.skip -Dsonar.projectKey=lengors_maven-java-template |
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,51 @@ | ||
--- | ||
name: Validate pull request | ||
|
||
on: | ||
pull_request: | ||
branches: | ||
- main | ||
- beta | ||
- alpha | ||
- dev | ||
|
||
jobs: | ||
check-style: | ||
name: Check code style | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v4 | ||
- name: Setup JDK 21 | ||
uses: actions/setup-java@v4 | ||
with: | ||
java-version: "21" | ||
distribution: temurin | ||
cache: maven | ||
- name: Perform style check | ||
run: ./mvnw checkstyle:check | ||
|
||
build-and-test: | ||
name: Build and test project | ||
strategy: | ||
matrix: | ||
os: | ||
- macos-latest | ||
- ubuntu-latest | ||
- windows-latest | ||
distribution: | ||
- temurin | ||
- zulu | ||
runs-on: ${{ matrix.os }} | ||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v4 | ||
- name: Setup JDK 21 | ||
uses: actions/setup-java@v4 | ||
with: | ||
java-version: "21" | ||
distribution: ${{ matrix.distribution }} | ||
cache: maven | ||
- name: Perform build and tests | ||
run: ./mvnw clean package | ||
|
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,65 @@ | ||
# Build files | ||
target/ | ||
!.mvn/wrapper/maven-wrapper.jar | ||
!**/src/main/**/target/ | ||
!**/src/test/**/target/ | ||
|
||
# Compiled class file | ||
*.class | ||
|
||
# Log file | ||
*.log | ||
|
||
# BlueJ files | ||
*.ctxt | ||
|
||
# Mobile Tools for Java (J2ME) | ||
.mtj.tmp/ | ||
|
||
# Package Files # | ||
*.jar | ||
*.war | ||
*.nar | ||
*.ear | ||
*.zip | ||
*.tar.gz | ||
*.rar | ||
|
||
# virtual machine crash logs, see http://www.java.com/en/download/help/error_hotspot.xml | ||
hs_err_pid* | ||
replay_pid* | ||
|
||
### IntelliJ IDEA ### | ||
.idea/modules.xml | ||
.idea/jarRepositories.xml | ||
.idea/compiler.xml | ||
.idea/libraries/ | ||
.idea/ | ||
*.iws | ||
*.iml | ||
*.ipr | ||
|
||
### Eclipse ### | ||
.apt_generated | ||
.classpath | ||
.factorypath | ||
.project | ||
.settings | ||
.springBeans | ||
.sts4-cache | ||
|
||
### NetBeans ### | ||
/nbproject/private/ | ||
/nbbuild/ | ||
/dist/ | ||
/nbdist/ | ||
/.nb-gradle/ | ||
build/ | ||
!**/src/main/**/build/ | ||
!**/src/test/**/build/ | ||
|
||
### VS Code ### | ||
.vscode/ | ||
|
||
### Mac OS ### | ||
.DS_Store |
Oops, something went wrong.