Skip to content

Commit

Permalink
Merge pull request #343 from gsmet/various-adjustments
Browse files Browse the repository at this point in the history
Various adjustments
  • Loading branch information
gsmet authored Dec 16, 2024
2 parents 83b4cc6 + bd6c9f8 commit 3bd225d
Show file tree
Hide file tree
Showing 15 changed files with 30 additions and 23 deletions.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
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
17 changes: 17 additions & 0 deletions docs/modules/ROOT/pages/developer-reference.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -196,6 +196,23 @@ For instance, you can set output variables, attach a job summary...
All these commands are made available through a `io.quarkiverse.githubaction.Commands` instance,
that you can inject into your action methods.

==== Logging

While you can use standard Java logging, using `Commands` log facilities may be more practical
as the logging appears in the job summary:

image::developer-reference/commands-logging-log.png[Logging in log]

image::developer-reference/commands-logging-job-summary.png[Logging in job summary]

`Commands` exposes the `debug()`, `notice()`, `warning()`, and `error()` methods.

[TIP]
====
For `debug()`, see https://docs.github.com/en/actions/monitoring-and-troubleshooting-workflows/enabling-debug-logging[Enabling debug logging]
for more information about how to enable the debug output when your actions are executed.
====

==== Outputs

Outputs are an important part of GitHub Actions.
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
./mvnw -B clean deploy -Dquarkus.package.jar.type=uber-jar -Dquarkus.package.jar.add-runner-suffix=false
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
quarkus.banner.enabled=false
quarkus.log.level=SEVERE
quarkus.log.category."io.quarkus".level=WARN
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
./mvnw -B clean deploy -Dquarkus.package.jar.type=uber-jar -Dquarkus.package.jar.add-runner-suffix=false
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
quarkus.banner.enabled=false
quarkus.log.level=SEVERE
quarkus.log.category."io.quarkus".level=WARN
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
./mvnw -B clean deploy -Dquarkus.package.jar.type=uber-jar -Dquarkus.package.jar.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
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<id>flatten</id>
<activation>
<property>
<name>quarkus.package.type</name>
<name>quarkus.package.jar.type</name>
<value>uber-jar</value>
</property>
</activation>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
quarkus:
log:
level: SEVERE
category:
"io.quarkus":
level: WARN
banner:
enabled: false

0 comments on commit 3bd225d

Please sign in to comment.