Skip to content

Commit

Permalink
Merge pull request #157 from maddingo/feature/enable-deploy
Browse files Browse the repository at this point in the history
Feature/enable deploy
  • Loading branch information
maddingo authored Dec 27, 2024
2 parents c050b5d + d2c30ce commit 9a4d94b
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 21 deletions.
17 changes: 11 additions & 6 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,13 @@ on:
java-version:
description: 'Java version'
required: true
type: choice
options:
- '21'
- '8'
- '11'
- '17'
default: '21'
validation:
pattern: '^(8|11|17|21)$'
error: 'Must be one of: 8, 11, 17, 21'
do-build:
description: 'Build the project'
required: true
Expand All @@ -24,7 +27,9 @@ on:
jobs:
deploy:
runs-on: ubuntu-24.04

permissions:
pages: write
packages: write
steps:
- uses: actions/checkout@v4
- name: Set up JDK ${{ inputs.java-version }}
Expand All @@ -42,7 +47,7 @@ jobs:
${{ runner.os }}-maven-${{ inputs.java-version }}
- name: Deploy with Maven
if: inputs.do-build
run: mvn -B deploy -DskipTests
run: mvn -B deploy -DskipTests -P github
- name: Maven Site
if: inputs.do-site
run: mvn -B site site:stage scm-publish:publish-scm
run: mvn -B site site:stage scm-publish:publish-scm -P github
4 changes: 4 additions & 0 deletions .github/workflows/maven.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,10 @@ on:
branches: [ "master" ]
pull_request:
branches: [ "master" ]
paths-ignore:
- .github/workflows/deploy.yml
- README.md
- '**/site/**'

jobs:
build:
Expand Down
21 changes: 6 additions & 15 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -341,23 +341,14 @@

<profiles>
<profile>
<id>local</id>
<activation>
<property>
<name>env.MAVEN_PROFILE</name>
<value>local</value>
</property>
</activation>
<properties>
<devlocal.base>file://${env.PWD}/target</devlocal.base>
</properties>
<id>github</id>
<distributionManagement>
<site>
<id>local</id>
<name>Local Deployment</name>
<url>${devlocal.base}/site</url>
<id>github-pages</id>
<name>Github Pages</name>
<url>https://github.com/maddingo/nio-fs-provider.git</url>
</site>
<repository>
<!--repository>
<id>dev-local</id>
<url>${devlocal.base}/repository</url>
<releases>
Expand All @@ -374,7 +365,7 @@
<updatePolicy>always</updatePolicy>
<checksumPolicy>fail</checksumPolicy>
</snapshots>
</snapshotRepository>
</snapshotRepository-->
</distributionManagement>
</profile>
<profile>
Expand Down

0 comments on commit 9a4d94b

Please sign in to comment.