4 Commits

Author SHA1 Message Date
ff43cac4ad Merge pull request #7 from s4u/action-name
Simplify action name
2021-08-30 19:49:36 +02:00
cac57cc0b0 Simplify action name 2021-08-30 19:44:30 +02:00
490f541598 Merge pull request #5 from s4u/checkout
Use actions/checkout
2021-08-30 08:37:39 +02:00
638a374dff Use actions/checkout 2021-08-30 08:33:27 +02:00
2 changed files with 29 additions and 6 deletions

View File

@ -1,19 +1,22 @@
# Setup Maven with settings.xml
# Setup Maven Action
[![Test](https://github.com/s4u/setup-maven-action/actions/workflows/test.yml/badge.svg)](https://github.com/s4u/setup-maven-action/actions/workflows/test.yml)
This is composite action which help to prepare GitHub Actions environment for Maven build by calling:
- [actions/checkout](https://github.com/marketplace/actions/checkout)
- [actions/setup-java](https://github.com/marketplace/actions/setup-java-jdk)
- [actions/cache](https://github.com/marketplace/actions/cache)
- [stCarolas/setup-maven](https://github.com/marketplace/actions/setup-maven)
- [s4u/maven-settings-action](https://github.com/marketplace/actions/maven-settings-action)
# 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 to use the latest and specific release version.
@ -22,6 +25,13 @@ or use automatic tools like [Dependabot](https://docs.github.com/en/code-securit
# Params mapping for sub actions
## checkout
| params | destination |
| -------------------------- |------------------ |
| checkout-fetch-depth | fetch-depth |
## setup-java
| params | destination | default |
@ -82,13 +92,13 @@ jobs:
name: Maven ${{ matrix.maven }} sample
steps:
- uses: actions/checkout@v2
- name: Setup Maven with settings.xml
uses: s4u/setup-maven-action@v1.0.0
- name: Setup Maven Action
uses: s4u/setup-maven-action@< version >
with:
java-version: 8
maven-version: ${{ matrix.maven }}
- run: mvn -V ...
```

View File

@ -1,5 +1,5 @@
name: 'Setup Maven with settings.xml'
description: 'Setup environment for Maven build'
name: 'Setup Maven Action'
description: 'Complete environment configuration for Maven builds'
branding:
icon: 'settings'
@ -7,6 +7,11 @@ branding:
inputs:
# checkout
checkout-fetch-depth:
description: 'Number of commits to fetch'
required: false
# java jdk params
java-version:
@ -60,6 +65,14 @@ runs:
steps:
- run: echo "::group::Checkout"
shell: bash
- uses: actions/checkout@v2.3.4
with:
fetch-depth: '${{ inputs.checkout-fetch-depth }}'
- run: echo "::endgroup::"
shell: bash
- run: echo "::group::Setup Java"
shell: bash
- uses: actions/setup-java@v2.3.0