From 9a62e2a3e9bad7b54cdf7a62ea2f1dcc82962c54 Mon Sep 17 00:00:00 2001 From: James Netherton Date: Tue, 9 Jul 2024 10:07:39 +0100 Subject: [PATCH] Remove prefix from shell code snippets --- .../create-jvm-only-extension.adoc | 4 +- .../contributor-guide/create-new-example.adoc | 4 +- .../create-new-extension.adoc | 6 +- .../contributor-guide/extension-metadata.adoc | 2 +- .../ROOT/pages/contributor-guide/index.adoc | 10 +- .../promote-jvm-to-native.adoc | 10 +- .../contributor-guide/release-guide.adoc | 165 +++++++++--------- .../pages/reference/extensions/cxf-soap.adoc | 2 +- .../ROOT/pages/reference/extensions/jfr.adoc | 4 +- .../ROOT/pages/user-guide/command-mode.adoc | 9 +- .../ROOT/pages/user-guide/first-steps.adoc | 30 ++-- .../cxf-soap/runtime/src/main/doc/usage.adoc | 2 +- .../jfr/runtime/src/main/doc/usage.adoc | 4 +- 13 files changed, 123 insertions(+), 129 deletions(-) diff --git a/docs/modules/ROOT/pages/contributor-guide/create-jvm-only-extension.adoc b/docs/modules/ROOT/pages/contributor-guide/create-jvm-only-extension.adoc index a9e8047342bc..150397ffb0dd 100644 --- a/docs/modules/ROOT/pages/contributor-guide/create-jvm-only-extension.adoc +++ b/docs/modules/ROOT/pages/contributor-guide/create-jvm-only-extension.adoc @@ -28,8 +28,8 @@ for the following: + [source,shell] ---- -$ cd camel-quarkus -$ mvn cq:create -N -Dcq.artifactIdBase=foo-abc -Dcq.nativeSupported=false +cd camel-quarkus +mvn cq:create -N -Dcq.artifactIdBase=foo-abc -Dcq.nativeSupported=false ---- + * A basic integration test is generated for you. It just checks that the newly added Camel component can be loaded. diff --git a/docs/modules/ROOT/pages/contributor-guide/create-new-example.adoc b/docs/modules/ROOT/pages/contributor-guide/create-new-example.adoc index 2444464b5be1..701d7fe63438 100644 --- a/docs/modules/ROOT/pages/contributor-guide/create-new-example.adoc +++ b/docs/modules/ROOT/pages/contributor-guide/create-new-example.adoc @@ -18,8 +18,8 @@ This guide outlines how to contribute a new example project to https://github.co + [source,shell] ---- -$ cd camel-quarkus-examples -$ mvn org.l2x6.cq:cq-maven-plugin:create-example -Dcq.artifactIdBase="yaml-to-log" -Dcq.exampleName="YAML To Log" -Dcq.exampleDescription="Shows how to use a YAML route with the log EIP" +cd camel-quarkus-examples +mvn org.l2x6.cq:cq-maven-plugin:create-example -Dcq.artifactIdBase="yaml-to-log" -Dcq.exampleName="YAML To Log" -Dcq.exampleDescription="Shows how to use a YAML route with the log EIP" ---- + Where: diff --git a/docs/modules/ROOT/pages/contributor-guide/create-new-extension.adoc b/docs/modules/ROOT/pages/contributor-guide/create-new-extension.adoc index 208ab6f79bb1..e2e8aa704968 100644 --- a/docs/modules/ROOT/pages/contributor-guide/create-new-extension.adoc +++ b/docs/modules/ROOT/pages/contributor-guide/create-new-extension.adoc @@ -18,8 +18,8 @@ + [source,shell] ---- -$ cd camel-quarkus -$ mvn cq:create -N -Dcq.artifactIdBase=foo-abc +cd camel-quarkus +mvn cq:create -N -Dcq.artifactIdBase=foo-abc ---- + where: @@ -80,7 +80,7 @@ Check the xref:contributor-guide/extension-metadata.adoc[Extension metadata] pag + [source,shell] ---- -$ mvn process-resources -Pformat +mvn process-resources -Pformat ---- + The above command will perform the following tasks: diff --git a/docs/modules/ROOT/pages/contributor-guide/extension-metadata.adoc b/docs/modules/ROOT/pages/contributor-guide/extension-metadata.adoc index 95f192b5d2eb..8f5fb391c735 100644 --- a/docs/modules/ROOT/pages/contributor-guide/extension-metadata.adoc +++ b/docs/modules/ROOT/pages/contributor-guide/extension-metadata.adoc @@ -23,7 +23,7 @@ the source tree: [source,shell] ---- -$ mvn -N cq:update-quarkus-metadata +mvn -N cq:update-quarkus-metadata ---- The data comes from the following diff --git a/docs/modules/ROOT/pages/contributor-guide/index.adoc b/docs/modules/ROOT/pages/contributor-guide/index.adoc index a57f6842c60a..2d4d4539a09f 100644 --- a/docs/modules/ROOT/pages/contributor-guide/index.adoc +++ b/docs/modules/ROOT/pages/contributor-guide/index.adoc @@ -21,29 +21,29 @@ Checkout the code [source,shell] ---- -$ git clone https://github.com/apache/camel-quarkus.git -$ cd camel-quarkus +git clone https://github.com/apache/camel-quarkus.git +cd camel-quarkus ---- A fast build without tests and various checks: [source,shell] ---- -$ mvn clean install -Dquickly +mvn clean install -Dquickly ---- A build with integration tests in the JVM mode only: [source,shell] ---- -$ mvn clean install +mvn clean install ---- A build with integration tests in both the JVM mode and the native mode: [source,shell] ---- -$ mvn clean install -Pnative +mvn clean install -Pnative ---- TIP: You may want to install and use https://github.com/mvndaemon/mvnd[`mvnd` - the Maven Daemon] for faster builds. diff --git a/docs/modules/ROOT/pages/contributor-guide/promote-jvm-to-native.adoc b/docs/modules/ROOT/pages/contributor-guide/promote-jvm-to-native.adoc index 763dc5ca8ed1..9ffd83a6c8ff 100644 --- a/docs/modules/ROOT/pages/contributor-guide/promote-jvm-to-native.adoc +++ b/docs/modules/ROOT/pages/contributor-guide/promote-jvm-to-native.adoc @@ -18,8 +18,8 @@ Please find some guiding steps below to start this quest: + [source,shell] ---- -$ cd camel-quarkus -$ mvn -N cq:promote -Dcq.artifactIdBase=... +cd camel-quarkus +mvn -N cq:promote -Dcq.artifactIdBase=... ---- + where `cq.artifactIdBase` needs to be set to the unique part of the `artifactId` of the extension you are @@ -42,8 +42,8 @@ The `promote` mojo does the following for you: + [source,shell] ---- -$ cd integration-tests/foo -$ mvn clean verify -Pnative +cd integration-tests/foo +mvn clean verify -Pnative ---- + Consider shifting some tasks from runtime to build time. @@ -53,7 +53,7 @@ The https://quarkus.io/guides/extension-authors-guide[Quarkus extension author's + [source,shell] ---- -$ mvn clean install -DskipTests -Pformat +mvn clean install -DskipTests -Pformat ---- 7. Squash your commits before sending a pull request. diff --git a/docs/modules/ROOT/pages/contributor-guide/release-guide.adoc b/docs/modules/ROOT/pages/contributor-guide/release-guide.adoc index 06badd1a292d..89211cddcb03 100644 --- a/docs/modules/ROOT/pages/contributor-guide/release-guide.adoc +++ b/docs/modules/ROOT/pages/contributor-guide/release-guide.adoc @@ -21,13 +21,13 @@ xref:manual::release-guide.adoc[Camel Release guide]. [source,shell] ---- -$ export VERSION=$(mvn help:evaluate -Dexpression=project.version -q -DforceStdout | sed 's|-SNAPSHOT||') # the version you are releasing, e.g. 0.1.0 -$ export NEXT_VERSION=$(echo ${VERSION} | awk -F. -v OFS=. '{$NF++;print}')-SNAPSHOT # the next development iteration, e.g. 0.1.1-SNAPSHOT -$ export BRANCH=$(echo $VERSION | sed 's|.[0-9][0-9]*$|.x|') # the release branch, e.g. 0.1.x -$ git fetch upstream # upstream is git@github.com:apache/camel-quarkus.git -$ git checkout main # main is the branch from which you want to release -$ git reset --hard upstream/main # make sure you are in sync with upstream -$ git checkout -b $BRANCH +export VERSION=$(mvn help:evaluate -Dexpression=project.version -q -DforceStdout | sed 's|-SNAPSHOT||') # the version you are releasing, e.g. 0.1.0 +export NEXT_VERSION=$(echo ${VERSION} | awk -F. -v OFS=. '{$NF++;print}')-SNAPSHOT # the next development iteration, e.g. 0.1.1-SNAPSHOT +export BRANCH=$(echo $VERSION | sed 's|.[0-9][0-9]*$|.x|') # the release branch, e.g. 0.1.x +git fetch upstream # upstream is git@github.com:apache/camel-quarkus.git +git checkout main # main is the branch from which you want to release +git reset --hard upstream/main # make sure you are in sync with upstream +git checkout -b $BRANCH ---- == `release:prepare` and `release:perform` @@ -39,7 +39,7 @@ The Maven command to release is as follows: [source,shell] ---- -$ mvn clean release:clean release:prepare -DreleaseVersion=$VERSION -DdevelopmentVersion=$NEXT_VERSION -B release:perform +mvn clean release:clean release:prepare -DreleaseVersion=$VERSION -DdevelopmentVersion=$NEXT_VERSION -B release:perform ---- In case `release:prepare` is successful but an issue occurs during `release:perform`, you can resume from the failing artifact to save some time: @@ -58,7 +58,7 @@ $ cd target/checkout + [source,shell] ---- -$ mvn deploy -Papache-release -DskipTests -Denforcer.skip -Dquarkus.build.skip -Dformatter.skip -Dimpsort.skip -rf :camel-quarkus-openapi-java +mvn deploy -Papache-release -DskipTests -Denforcer.skip -Dquarkus.build.skip -Dformatter.skip -Dimpsort.skip -rf :camel-quarkus-openapi-java ---- == Close the Apache staging repository @@ -78,17 +78,17 @@ In a first step, make sure your public key is present in the `KEYS` file. Add it [source,shell] ---- -$ export EMAIL= # the e-mail address in your key -$ gpg -k $EMAIL >> KEYS -$ gpg --armor --export $EMAIL >> KEYS +export EMAIL= # the e-mail address in your key +gpg -k $EMAIL >> KEYS +gpg --armor --export $EMAIL >> KEYS ---- Then execute the `upload-source.sh` script, like below: [source,shell] ---- -$ cd release-utils/scripts/ -$ ./upload-source.sh $VERSION $VERSION +cd release-utils/scripts/ +./upload-source.sh $VERSION $VERSION ---- This will take care of grabbing the source zip from github and getting the SBOMs from target directory. After signing the files, it will push the folder to `dist/dev/` @@ -111,7 +111,7 @@ For instance, running the tool to compare the `2.10.0` staging release against t [source,shell] ---- -$ java -jar target/quarkus-app/quarkus-run.jar -an 2.9.0 2.10.0 +java -jar target/quarkus-app/quarkus-run.jar -an 2.9.0 2.10.0 ---- After approximately 1 hour, it should generate a report like below: @@ -138,8 +138,8 @@ For more details about options, please run: [source,shell] ---- -$ cd tooling/perf-regression -$ java -jar target/quarkus-app/quarkus-run.jar --help +cd tooling/perf-regression +java -jar target/quarkus-app/quarkus-run.jar --help ---- == Start an upstream vote @@ -166,16 +166,16 @@ SNAPSHOT (the next minor SNAPSHOT of `0.1.0` is `0.2.0-SNAPSHOT`). [source,shell] ---- -$ NEXT_RELEASE=... # e.g. 0.2.0 -$ NEXT_SNAPSHOT="${NEXT_RELEASE}-SNAPSHOT" -$ git checkout "main" -$ git reset upstream/main -$ mvn release:update-versions -DautoVersionSubmodules=true -DdevelopmentVersion=$NEXT_SNAPSHOT -B -$ sed -i "s|[^<]*|$NEXT_RELEASE|" tooling/create-extension-templates/runtime-pom.xml -$ sed -i "s|[^<]*|$NEXT_RELEASE|" tooling/create-extension-templates/runtime-pom.xml -$ mvn cq:sync-versions -N -$ mvn clean install -DskipTests -Dquarkus.build.skip # to regen the Qute Camel component metadata + flattened boms -$ git commit -am "Next is $NEXT_SNAPSHOT" +NEXT_RELEASE=... # e.g. 0.2.0 +NEXT_SNAPSHOT="${NEXT_RELEASE}-SNAPSHOT" +git checkout "main" +git reset upstream/main +mvn release:update-versions -DautoVersionSubmodules=true -DdevelopmentVersion=$NEXT_SNAPSHOT -B +sed -i "s|[^<]*|$NEXT_RELEASE|" tooling/create-extension-templates/runtime-pom.xml +sed -i "s|[^<]*|$NEXT_RELEASE|" tooling/create-extension-templates/runtime-pom.xml +mvn cq:sync-versions -N +mvn clean install -DskipTests -Dquarkus.build.skip # to regen the Qute Camel component metadata + flattened boms +git commit -am "Next is $NEXT_SNAPSHOT" # Send a pull request ---- @@ -207,9 +207,9 @@ In a first step, one would simply need to promote the deliverables from the deve [source,shell] ---- -$ export VERSION=$(mvn help:evaluate -Dexpression=project.version -q -DforceStdout | sed 's|-SNAPSHOT||') # the version you are releasing, e.g. 0.1.0 -$ cd release-utils/scripts/ -$ ./promote-release.sh $VERSION $VERSION +export VERSION=$(mvn help:evaluate -Dexpression=project.version -q -DforceStdout | sed 's|-SNAPSHOT||') # the version you are releasing, e.g. 0.1.0 +cd release-utils/scripts/ +./promote-release.sh $VERSION $VERSION ---- In a second step, it is needed to check that useless versions are deleted from the svn repository. @@ -217,16 +217,16 @@ If you are doing this for the first time you need to checkout the Apache Camel Q [source,shell] ---- -$ svn checkout 'https://dist.apache.org/repos/dist/release/camel' camel-releases-dist +svn checkout 'https://dist.apache.org/repos/dist/release/camel' camel-releases-dist ---- In case you have performed the above step during some release in the past, you need to update your working copy: [source,shell] ---- -$ cd camel-releases-dist -$ svn update . -$ cd "camel-quarkus/$VERSION" +cd camel-releases-dist +svn update . +cd "camel-quarkus/$VERSION" ---- Then, ensure that only the latest release from each maintained branches is present (including active LTS versions). @@ -234,20 +234,19 @@ Typically, when releasing e.g. 3.12.0, you may need to delete e.g. 3.11.0: [source,shell] ---- -$ cd .. -$ ls -3.11.0 3.12.0 -$ svn remove 3.11.0 +cd .. +ls +svn remove 3.11.0 ---- Review and commit the changes: [source,shell] ---- -$ cd .. -$ svn diff -$ svn add --force . -$ svn commit -m "Cleaning inactive Camel Quarkus versions after $VERSION release" +cd .. +svn diff +svn add --force . +svn commit -m "Cleaning inactive Camel Quarkus versions after $VERSION release" ---- == Upgrade Camel Quarkus in Quarkus Platform @@ -262,8 +261,8 @@ You may find the `await-release` mojo of `cq-maven-plugin` handy if you need to [source,shell] ---- -$ cd camel-quarkus -$ mvn cq:await-release -Dcq.version=$(git describe --tags `git rev-list --tags --max-count=1`) +cd camel-quarkus +mvn cq:await-release -Dcq.version=$(git describe --tags `git rev-list --tags --max-count=1`) ---- The mojo first lists the artifacts having `groupId` `org.apache.camel.quarkus` and the given `$VERSION` @@ -278,18 +277,18 @@ https://{link-quarkus-code-generator}/[{link-quarkus-code-generator}] as well as + [source,shell] ---- -$ git clone git@github.com:quarkusio/quarkus-platform.git +git clone git@github.com:quarkusio/quarkus-platform.git ---- + * Change `camel-quarkus.version` property in the Quarkus platform top level `https://github.com/quarkusio/quarkus-platform/blob/main/pom.xml#L54[pom.xml]` to the newly released version: + [source,shell] ---- -$ cd quarkus-platform -$ export NEW_VERSION=... # the version you just released, e.g. 0.1.0 -$ sed -i "s|[^<]*|$NEW_VERSION|" pom.xml +cd quarkus-platform +export NEW_VERSION=... # the version you just released, e.g. 0.1.0 +sed -i "s|[^<]*|$NEW_VERSION|" pom.xml # Make sure that it worked -$ git status +git status ---- + * Review the list of skipped tests configured on the Camel member in `pom.xml` (E.g ones that have `true`). If any are known to have been fixed in the latest release, remove the entries so that they can be enabled again. @@ -298,18 +297,18 @@ $ git status + [source,shell] ---- -$ ./mvnw clean install -DskipTests +./mvnw clean install -DskipTests # ^ This will take a couple of minutes because it resolves # every single dependency of every single extension included # in the platform # # double check files are well formatted -$ ./mvnw -Dsync +./mvnw -Dsync # Then commit the generated changes -$ git add -A -$ git commit -m "Upgrade to Camel Quarkus $NEW_VERSION" +git add -A +git commit -m "Upgrade to Camel Quarkus $NEW_VERSION" ---- + * Run Camel Quarkus integration tests at least in JVM mode: @@ -369,20 +368,20 @@ In this case, right after the newest Quarkus Platform becomes available on https + [source,shell] ---- -$ NEW_PLATFORM_VERSION=... # E.g. 2.2.0.Final -$ git fetch upstream -$ git checkout camel-quarkus-main -$ git reset --hard upstream/camel-quarkus-main -$ mvn org.l2x6.cq:cq-maven-plugin:2.10.0:examples-set-platform -Dcq.quarkus.platform.version=$NEW_PLATFORM_VERSION -$ git add -A -$ git commit -m "Upgrade to Quarkus Platform $NEW_PLATFORM_VERSION" +NEW_PLATFORM_VERSION=... # E.g. 2.2.0.Final +git fetch upstream +git checkout camel-quarkus-main +git reset --hard upstream/camel-quarkus-main +mvn org.l2x6.cq:cq-maven-plugin:2.10.0:examples-set-platform -Dcq.quarkus.platform.version=$NEW_PLATFORM_VERSION +git add -A +git commit -m "Upgrade to Quarkus Platform $NEW_PLATFORM_VERSION" ---- + * Make sure that the tests are still passing: + [source,shell] ---- -$ ./mvnw-for-each.sh clean verify -Dnative +./mvnw-for-each.sh clean verify -Dnative ---- + * If everything works for you locally, open a PR to merge `camel-quarkus-main` to `main` @@ -390,37 +389,37 @@ $ ./mvnw-for-each.sh clean verify -Dnative + [source,shell] ---- -$ NEW_CQ_VERSION=... # the recent release of Camel Quarkus; e.g. 2.2.0 -$ git checkout main -$ git fetch upstream -$ git reset --hard upstream/main -$ ./mvnw-for-each.sh versions:set -DnewVersion=$NEW_CQ_VERSION +NEW_CQ_VERSION=... # the recent release of Camel Quarkus; e.g. 2.2.0 +git checkout main +git fetch upstream +git reset --hard upstream/main +./mvnw-for-each.sh versions:set -DnewVersion=$NEW_CQ_VERSION # Update version labels in Kubernetes resources -$ ./mvnw-for-each.sh process-sources -$ git add -A -$ git commit -m "Tag $NEW_CQ_VERSION" -$ git tag $NEW_CQ_VERSION -$ git push upstream main -$ git push upstream $NEW_CQ_VERSION +./mvnw-for-each.sh process-sources +git add -A +git commit -m "Tag $NEW_CQ_VERSION" +git tag $NEW_CQ_VERSION +git push upstream main +git push upstream $NEW_CQ_VERSION # Create a maintenance branch for the release unless this is a micro release -$ export BRANCH=$(echo $NEW_CQ_VERSION | sed 's|.[0-9][0-9]*$|.x|') -$ git checkout -b $BRANCH $NEW_CQ_VERSION -$ git push upstream $BRANCH +export BRANCH=$(echo $NEW_CQ_VERSION | sed 's|.[0-9][0-9]*$|.x|') +git checkout -b $BRANCH $NEW_CQ_VERSION +git push upstream $BRANCH ---- + * Prepare the `camel-quarkus-main` branch for the next development iteration: + [source,shell] ---- -$ NEXT_CQ_VERSION=... # The version used in the current Camel Quarkus main branch without the -SNAPSHOT suffix; e.g. 2.3.0 -$ git checkout camel-quarkus-main -$ git reset --hard main -$ ./mvnw org.l2x6.cq:cq-maven-plugin:2.10.0:examples-set-platform -Dcq.camel-quarkus.version=${NEXT_CQ_VERSION}-SNAPSHOT -Dcq.newVersion=${NEXT_CQ_VERSION}-SNAPSHOT +NEXT_CQ_VERSION=... # The version used in the current Camel Quarkus main branch without the -SNAPSHOT suffix; e.g. 2.3.0 +git checkout camel-quarkus-main +git reset --hard main +./mvnw org.l2x6.cq:cq-maven-plugin:2.10.0:examples-set-platform -Dcq.camel-quarkus.version=${NEXT_CQ_VERSION}-SNAPSHOT -Dcq.newVersion=${NEXT_CQ_VERSION}-SNAPSHOT # Update version labels in Kubernetes resources -$ ./mvnw-for-each.sh process-sources -$ git add -A -$ git commit -m "Next is $NEXT_CQ_VERSION" -$ git push upstream camel-quarkus-main --force-with-lease +./mvnw-for-each.sh process-sources +git add -A +git commit -m "Next is $NEXT_CQ_VERSION" +git push upstream camel-quarkus-main --force-with-lease ---- == Write the release announcement blog post diff --git a/docs/modules/ROOT/pages/reference/extensions/cxf-soap.adoc b/docs/modules/ROOT/pages/reference/extensions/cxf-soap.adoc index 722817b74997..25ed035ce6f1 100644 --- a/docs/modules/ROOT/pages/reference/extensions/cxf-soap.adoc +++ b/docs/modules/ROOT/pages/reference/extensions/cxf-soap.adoc @@ -135,7 +135,7 @@ You can test this client application against the https://quay.io/repository/l2x6 [source,shell] ---- -$ docker run -p 8082:8080 quay.io/l2x6/calculator-ws:1.2 +docker run -p 8082:8080 quay.io/l2x6/calculator-ws:1.2 ---- ==== diff --git a/docs/modules/ROOT/pages/reference/extensions/jfr.adoc b/docs/modules/ROOT/pages/reference/extensions/jfr.adoc index ca0c3c9aed88..59d75c755ef0 100644 --- a/docs/modules/ROOT/pages/reference/extensions/jfr.adoc +++ b/docs/modules/ROOT/pages/reference/extensions/jfr.adoc @@ -62,14 +62,14 @@ In JVM mode the application runnable JAR can be executed as follows. [source,shell] ---- -$ java -XX:+FlightRecorder -XX:StartFlightRecording=filename=recording.jfr -jar quarkus-run.jar +java -XX:+FlightRecorder -XX:StartFlightRecording=filename=recording.jfr -jar quarkus-run.jar ---- In native mode, the native executable can be executed as follows. [source,shell] ---- -$ ./my-application-runner -XX:+FlightRecorder -XX:StartFlightRecording=filename=recording.jfr +./my-application-runner -XX:+FlightRecorder -XX:StartFlightRecording=filename=recording.jfr ---- [id="extensions-jfr-usage-flight-recording-in-native-mode"] diff --git a/docs/modules/ROOT/pages/user-guide/command-mode.adoc b/docs/modules/ROOT/pages/user-guide/command-mode.adoc index c3f6ebf35701..17511b6d2f24 100644 --- a/docs/modules/ROOT/pages/user-guide/command-mode.adoc +++ b/docs/modules/ROOT/pages/user-guide/command-mode.adoc @@ -167,13 +167,8 @@ GraalVM with `native-image` command installed and `GRAALVM_HOME` environment var [source,shell] ---- -$ export GRAALVM_HOME=... -$ mvn clean package -Pnative -... -$ ls -lh target -... --rwxr-xr-x. 1 ppalaga ppalaga 33M Jul 15 11:48 command-mode-runner -... +export GRAALVM_HOME=... +mvn clean package -Pnative ---- The basic command line application compiled into a Linux native diff --git a/docs/modules/ROOT/pages/user-guide/first-steps.adoc b/docs/modules/ROOT/pages/user-guide/first-steps.adoc index 0905d3c8fdf4..ab7617854818 100644 --- a/docs/modules/ROOT/pages/user-guide/first-steps.adoc +++ b/docs/modules/ROOT/pages/user-guide/first-steps.adoc @@ -33,12 +33,12 @@ Quarkus provides a Maven plugin that enables you to quickly bootstrap projects. [source,shell,subs="attributes"] ---- -$ mvn io.quarkus:quarkus-maven-plugin:{quarkus-version}:create \ +mvn io.quarkus:quarkus-maven-plugin:{quarkus-version}:create \ -DprojectGroupId=org.acme \ -DprojectArtifactId=getting-started \ -Dextensions=camel-quarkus-log,camel-quarkus-timer -$ cd getting-started +cd getting-started ---- NOTE: Windows users should omit the `\` if using `cmd`. When using `Powershell`, wrap the `-D` parameters in double quotes. @@ -80,15 +80,15 @@ The main branch is always aligned with the latest Camel Quarkus release. + [source,shell] ---- -$ git clone https://github.com/apache/camel-quarkus-examples.git +git clone https://github.com/apache/camel-quarkus-examples.git ---- 2. Copy the `rest-json` example out of the source tree: + [source,shell] ---- -$ cp -r camel-quarkus-examples/rest-json . -$ cd rest-json +cp -r camel-quarkus-examples/rest-json . +cd rest-json ---- 3. Open the `pom.xml` file in your IDE. Change the project `groupId`, `artifactId` & `version` as necessary. @@ -124,7 +124,7 @@ The application is configured by properties defined within `src/main/resources/a [source,shell] ---- -$ mvn clean compile quarkus:dev +mvn clean compile quarkus:dev ---- This command compiles the project, starts your application and lets the Quarkus tooling watch for changes in your @@ -146,7 +146,7 @@ The JVM mode tests are run by `maven-surefire-plugin` in the `test` Maven phase: [source,shell] ---- -$ mvn clean test +mvn clean test ---- This should take about 15 seconds. @@ -156,7 +156,7 @@ activate the profile that runs them: [source,shell] ---- -$ mvn clean verify -Pnative +mvn clean verify -Pnative ---- This takes about 2.5 minutes (once you have all dependencies cached). @@ -169,8 +169,8 @@ This takes about 2.5 minutes (once you have all dependencies cached). [source,shell] ---- -$ mvn clean package -$ ls -lh target/quarkus-app +mvn clean package +ls -lh target/quarkus-app ... -rw-r--r--. 1 ppalaga ppalaga 238K Oct 11 18:55 quarkus-run.jar ... @@ -180,7 +180,7 @@ You can run it as follows: [source,shell] ---- -$ java -jar target/quarkus-app/quarkus-run.jar +java -jar target/quarkus-app/quarkus-run.jar ... [io.quarkus] (main) Quarkus started in 1.163s. Listening on: http://[::]:8080 ---- @@ -195,8 +195,8 @@ To prepare a native executable using GraalVM, run the following command: [source,shell] ---- -$ mvn clean package -Pnative -$ ls -lh target +mvn clean package -Pnative +ls -lh target ... -rwxr-xr-x. 1 ppalaga ppalaga 46M Oct 11 18:57 my-app-0.0.1-SNAPSHOT-runner ... @@ -207,7 +207,7 @@ it can be run directly: [source,shell] ---- -$ ./target/*-runner +./target/*-runner ... [io.quarkus] (main) Quarkus started in 0.013s. Listening on: http://[::]:8080 ... @@ -217,7 +217,7 @@ Check how fast it started and check how little memory it consumes: [source,shell] ---- -$ ps -o rss,command -p $(pgrep my-app) +ps -o rss,command -p $(pgrep my-app) RSS COMMAND 34916 ./target/my-app-0.0.1-SNAPSHOT-runner ---- diff --git a/extensions/cxf-soap/runtime/src/main/doc/usage.adoc b/extensions/cxf-soap/runtime/src/main/doc/usage.adoc index e9d2042a31e9..cc7a00ec1072 100644 --- a/extensions/cxf-soap/runtime/src/main/doc/usage.adoc +++ b/extensions/cxf-soap/runtime/src/main/doc/usage.adoc @@ -84,7 +84,7 @@ You can test this client application against the https://quay.io/repository/l2x6 [source,shell] ---- -$ docker run -p 8082:8080 quay.io/l2x6/calculator-ws:1.2 +docker run -p 8082:8080 quay.io/l2x6/calculator-ws:1.2 ---- ==== diff --git a/extensions/jfr/runtime/src/main/doc/usage.adoc b/extensions/jfr/runtime/src/main/doc/usage.adoc index 405a4599745c..898f79f2180b 100644 --- a/extensions/jfr/runtime/src/main/doc/usage.adoc +++ b/extensions/jfr/runtime/src/main/doc/usage.adoc @@ -13,14 +13,14 @@ In JVM mode the application runnable JAR can be executed as follows. [source,shell] ---- -$ java -XX:+FlightRecorder -XX:StartFlightRecording=filename=recording.jfr -jar quarkus-run.jar +java -XX:+FlightRecorder -XX:StartFlightRecording=filename=recording.jfr -jar quarkus-run.jar ---- In native mode, the native executable can be executed as follows. [source,shell] ---- -$ ./my-application-runner -XX:+FlightRecorder -XX:StartFlightRecording=filename=recording.jfr +./my-application-runner -XX:+FlightRecorder -XX:StartFlightRecording=filename=recording.jfr ---- === Flight recording in native mode