Skip to content

Commit

Permalink
Merge pull request #27421 from ia3andy/fix-cs-doc
Browse files Browse the repository at this point in the history
Minor but important fixes in codestart doc
  • Loading branch information
gsmet authored Aug 23, 2022
2 parents 22f3341 + 7328ef4 commit 81dab61
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions docs/src/main/asciidoc/extension-codestart.adoc
Original file line number Diff line number Diff line change
@@ -69,6 +69,8 @@ The https://github.com/quarkusio/quarkus/tree/main/independent-projects/tools/ba

== Writing an Extension Codestart

Here is a step-by-step guide to write an extension codestart. You may also watch the https://www.youtube.com/watch?v=lLyVDqVK8cE[Quarkus Insight #99] with a live-coding session.

As was mentioned previously, the base project files (pom.xml, Dockerfiles, ...) are already generated by the base codestarts provided by the Quarkus core. Thanks to this, we can only focus on the starter code specific to the extension.

Let's take `io.quarkiverse.aloha:quarkus-aloha` as an example extension GAV (don't look for this extension, it doesn't exist).
@@ -148,7 +150,7 @@ metadata:
artifact: "io.quarkiverse.aloha:quarkus-aloha:codestarts:jar:${project.version}"
----

* Add the readme <<readme-md>> section template in `base/readme.tpl.qute.md`:
* Add the readme <<readme-md>> section template in `base/README.tpl.qute.md`:
+
[source,html]
----
@@ -157,11 +159,11 @@ metadata:

* Run `mvn clean install` in the extension root (or just `runtime`).

* Now we can check that the codestart actually works by creating a project consuming our extension:
* Now we can check that the codestart actually works by creating a project consuming our extension (make sure the snapshot version is correct):
+
[source,bash]
----
quarkus create app aloha-app x=io.quarkiverse.aloha:quarkus-aloha:999-SNAPSHOT
quarkus create app aloha-app -x=io.quarkiverse.aloha:quarkus-aloha:999-SNAPSHOT
...
applying codestarts...
@@ -353,7 +355,7 @@ Those templates are able to use data which contains:
You may add a `README.md` or `README.tpl.qute.md` in the `base` directory, it will be appended to the others.
So just add the info relative to your extension codestart.

base/readme.tpl.qute.md
base/README.tpl.qute.md
[source,html]
----
{#include readme-header /}

0 comments on commit 81dab61

Please sign in to comment.