mirror of
https://github.com/s4u/setup-maven-action.git
synced 2026-02-13 00:05:10 +08:00
Compare commits
7 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| c1ef1c9458 | |||
| fe0723070c | |||
| f416ae1666 | |||
| 428a7bd6a8 | |||
| 7b66d0ca2e | |||
| 2dce5ee2b1 | |||
| e912d59387 |
6
.github/workflows/test.yml
vendored
6
.github/workflows/test.yml
vendored
@ -19,7 +19,7 @@ jobs:
|
||||
matrix:
|
||||
os: [ 'ubuntu-latest', 'windows-latest', 'macOS-latest' ]
|
||||
java: [ '8', '11', '17' ]
|
||||
maven: [ '3.6.3', '3.8.7', '3.9.2' ]
|
||||
maven: [ '3.8.8', '3.9.4' ]
|
||||
fail-fast: false
|
||||
|
||||
runs-on: ${{ matrix.os }}
|
||||
@ -44,10 +44,8 @@ jobs:
|
||||
- uses: actions/checkout@v3
|
||||
|
||||
- uses: ./
|
||||
with:
|
||||
java-version: 8
|
||||
|
||||
- run: mvn -V validate -Drequire.java=8 -Drequire.maven=3.9.2
|
||||
- run: mvn -V validate -Drequire.java=17 -Drequire.maven=3.9.4
|
||||
shell: bash
|
||||
|
||||
test-ok:
|
||||
|
||||
42
README.md
42
README.md
@ -9,37 +9,35 @@ This is composite action which help to prepare GitHub Actions environment for Ma
|
||||
- [stCarolas/setup-maven](https://github.com/marketplace/actions/setup-maven)
|
||||
- [s4u/maven-settings-action](https://github.com/marketplace/actions/maven-settings-action)
|
||||
|
||||
# Contributions
|
||||
:exclamation: You **should not** include above actions in your configuration - in other case those will be **called twice**. :exclamation:
|
||||
|
||||
- Contributions are welcome!
|
||||
- Give :star: - if you want to encourage me to work on a project
|
||||
- Don't hesitate to create issues for new features you dream of or if you suspect some bug
|
||||
For default values you only need:
|
||||
|
||||
# Project versioning
|
||||
```yml
|
||||
steps:
|
||||
|
||||
This project uses [Semantic Versioning](https://semver.org/).
|
||||
We recommended using the latest and specific release version.
|
||||
|
||||
In order to keep your project dependencies up to date you can watch this repository *(Releases only)*
|
||||
or use automatic tools like [Dependabot](https://docs.github.com/en/code-security/supply-chain-security/keeping-your-dependencies-updated-automatically/about-dependabot-version-updates).
|
||||
- name: Setup Maven Action
|
||||
uses: s4u/setup-maven-action@< version >
|
||||
|
||||
- run: mvn -V ...
|
||||
```
|
||||
|
||||
# Params mapping for sub actions
|
||||
|
||||
**Notice** when used this action you should not used mentioned below actions again.
|
||||
|
||||
## checkout
|
||||
|
||||
| params | destination | default |
|
||||
|------------------------------|---------------------|---------|
|
||||
| checkout-fetch-depth | fetch-depth | |
|
||||
| checkout-path | path | |
|
||||
| checkout-ref | ref | |
|
||||
| checkout-persist-credentials | persist-credentials | false |
|
||||
|
||||
## setup-java
|
||||
|
||||
| params | destination | default |
|
||||
|-------------------|--------------|---------|
|
||||
| java-version | java-version | |
|
||||
| java-version | java-version | 17 |
|
||||
| java-distribution | distribution | temurin |
|
||||
|
||||
## cache
|
||||
@ -69,7 +67,7 @@ So we can use for action:
|
||||
|
||||
| params | destination | default |
|
||||
|---------------|---------------|---------|
|
||||
| maven-version | maven-version | 3.9.2 |
|
||||
| maven-version | maven-version | 3.9.4 |
|
||||
|
||||
## maven-settings-action
|
||||
|
||||
@ -90,7 +88,7 @@ jobs:
|
||||
|
||||
strategy:
|
||||
matrix:
|
||||
maven: [ '3.6.3', '3.8.7', '3.9.2' ]
|
||||
maven: [ '3.8.8', '3.9.4' ]
|
||||
|
||||
name: Maven ${{ matrix.maven }} sample
|
||||
|
||||
@ -105,6 +103,20 @@ jobs:
|
||||
- run: mvn -V ...
|
||||
```
|
||||
|
||||
# Contributions
|
||||
|
||||
- Contributions are welcome!
|
||||
- Give :star: - if you want to encourage me to work on a project
|
||||
- Don't hesitate to create issues for new features you dream of or if you suspect some bug
|
||||
|
||||
# Project versioning
|
||||
|
||||
This project uses [Semantic Versioning](https://semver.org/).
|
||||
We recommended using the latest and specific release version.
|
||||
|
||||
In order to keep your project dependencies up to date you can watch this repository *(Releases only)*
|
||||
or use automatic tools like [Dependabot](https://docs.github.com/en/code-security/supply-chain-security/keeping-your-dependencies-updated-automatically/about-dependabot-version-updates).
|
||||
|
||||
# License
|
||||
|
||||
The scripts and documentation in this project are released under the [MIT License](LICENSE)
|
||||
|
||||
@ -21,11 +21,15 @@ inputs:
|
||||
default: 'false'
|
||||
required: false
|
||||
|
||||
checkout-ref:
|
||||
description: 'The branch, tag, or SHA of the repository to clone'
|
||||
required: false
|
||||
|
||||
# java jdk params
|
||||
|
||||
java-version:
|
||||
description: 'The Java version to set up'
|
||||
default: '17'
|
||||
required: true
|
||||
|
||||
java-distribution:
|
||||
@ -50,7 +54,7 @@ inputs:
|
||||
# maven version
|
||||
maven-version:
|
||||
description: 'The Maven version to set up'
|
||||
default: '3.9.2'
|
||||
default: '3.9.4'
|
||||
required: false
|
||||
|
||||
# maven settings.xml
|
||||
@ -80,6 +84,7 @@ runs:
|
||||
fetch-depth: '${{ inputs.checkout-fetch-depth }}'
|
||||
path: '${{ inputs.checkout-path }}'
|
||||
persist-credentials: '${{ inputs.checkout-persist-credentials }}'
|
||||
ref: '${{ inputs.checkout-ref }}'
|
||||
|
||||
- uses: actions/setup-java@v3
|
||||
with:
|
||||
|
||||
Reference in New Issue
Block a user