Skip to content

Commit

Permalink
Update the git index for make mvnw executable
Browse files Browse the repository at this point in the history
Instead of using chmod in the workflows.
  • Loading branch information
gsmet committed Dec 16, 2024
1 parent 6a49135 commit 25672c1
Show file tree
Hide file tree
Showing 8 changed files with 4 additions and 16 deletions.
6 changes: 4 additions & 2 deletions docs/modules/ROOT/pages/create-github-action.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -110,12 +110,14 @@ The next step is to push your GitHub Action to its GitHub repository (GitHub des
----
git init
git add .
git update-index --chmod=+x mvnw <1>
git commit -m "Init the project"
git branch -M main
git remote add origin [email protected]:my/action-github-repository.git <1>
git remote add origin [email protected]:my/action-github-repository.git <2>
git push -u origin main
----
<1> Replace `my/action-github-repository` with the full name of the repository you created to host the GitHub Action.
<1> Make sure `mvnw` is executable, even if the project is initialized on Windows.
<2> Replace `my/action-github-repository` with the full name of the repository you created to host the GitHub Action.

[WARNING]
====
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,4 @@ jobs:

- name: Build
run: |
# if the repository has been initialized with Windows, we need to set the permissions here
chmod 755 ./mvnw
./mvnw -B clean verify -Dquarkus.package.type=uber-jar -Dquarkus.package.add-runner-suffix=false
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,6 @@ jobs:
- name: Build and publish action to Maven repository
shell: bash
run: |
# if the repository has been initialized with Windows, we need to set the permissions here
chmod 755 ./mvnw
./mvnw -B clean deploy -Dquarkus.package.type=uber-jar -Dquarkus.package.add-runner-suffix=false
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,4 @@ jobs:

- name: Build
run: |
# if the repository has been initialized with Windows, we need to set the permissions here
chmod 755 ./mvnw
./mvnw -B clean verify -Dquarkus.package.type=uber-jar -Dquarkus.package.add-runner-suffix=false
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,6 @@ jobs:
- name: Build and publish action to Maven repository
shell: bash
run: |
# if the repository has been initialized with Windows, we need to set the permissions here
chmod 755 ./mvnw
./mvnw -B clean deploy -Dquarkus.package.type=uber-jar -Dquarkus.package.add-runner-suffix=false
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,4 @@ jobs:
{/if}
- name: Build
run: |
# if the repository has been initialized with Windows, we need to set the permissions here
chmod 755 ./mvnw
{buildtool.cli} {buildtool.cmd.build-ci}
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,6 @@ jobs:
- name: Build and publish action to Maven repository
shell: bash
run: |
# if the repository has been initialized with Windows, we need to set the permissions here
chmod 755 ./mvnw
./mvnw -B clean deploy -Dquarkus.package.type=uber-jar -Dquarkus.package.add-runner-suffix=false
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,6 @@ jobs:

- name: Build native image
run: |
# if the repository has been initialized with Windows, we need to set the permissions here
chmod 755 ./mvnw
./mvnw -B clean package -Dnative

- name: Log in to the Container registry
Expand Down

0 comments on commit 25672c1

Please sign in to comment.