-
Notifications
You must be signed in to change notification settings - Fork 38
Rework #11
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Rework #11
Conversation
Previously, it said that Spring created a `main` class. Now it says that Spring creates a `main` function in an Application class.
…tion to run the main method was lost; now it's back.
It appears that the tags were accidentally broken by Jay Bryant <jbryant@pivotal.io> in commit 42f92f2
* Adds a .gitignore * Adds configuration to `pom` for asciidoctor and restdocs * Updates the maven wrapper from 0.5.2 to 0.5.6
* Combine the .gitignores from maven and gradle * Moves from Spring Boot `2.3.2.RELEASE` to `2.4.1` * Adds asciidotor configuration to `build.gradle` * No longer explicity excludes vintage; according to @dsyer, that's already taken care of by Spring Boot. * Adds some updates to the gradle wrapper; moves from 6.5.1 to 6.7.1
People who know how to use an IDE will do so; providing brief instructions for people new to spring boot (and probably build systems) seems warranted in this beginners' tutorial.
…documentation". Also partially removed the instruction to add the dependencies as Spring Initializr has already added them.
README.adoc
Outdated
=== Maven | ||
|
||
If you use Maven, the following listing shows what to add to the `<dependencies>` | ||
section of `pom.xml`: | ||
|
||
==== | ||
[source,xml] | ||
---- | ||
include::complete/pom.xml[tag=test] | ||
include::complete/pom.xml[tag=restdocs-dependency] | ||
---- | ||
==== | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This section about adding dependencies to Maven/Gradle would go away, because Initializr would've already added them—unless I'm mistaken.
Let us not forget to
- remove the asciidoctor tags regarding adding a dependency
…cies are already included for you by Spring Initializr. Also removes the tags from complete's pom.xml, though we'll likely replace the whole pom later. Corrects paragraph about adding a contextLoads test as that test is already provided by Spring Initializr.
…equivalent `@ExtendWith`
…clarifies how snippets are first mentioned.
…arifies where `home` comes from.
…were previously added to the initial folder. Spring Boot from 2.3.2.RELEASE to 2.4.1 org.asciidoctor.convert from 1.5.6 to 1.5.8 Gradle Wrapper from 6.5.1 to 6.7.1 Maven Wrapper from 0.5.2 to 0.5.6 In 2.4+, Spring Initializr no longer has to exclude Junit Vintage. Spring Initialzr also now includes configuration for the asciidoctor-maven-plugin
…ll expect the snippets to be instead of the custom `target/snippets` folder.
…e place as maven: `src/main/asciidoc`. Also mentioned where to find the generated docs for both Maven and Gradle. For some reason gradle isn't generating the snippets; the folder yes, the snippets, no. ¯\_(ツ)_/¯ It does generate the asciidoc, but there's no snippets included.
} | ||
|
||
group = 'com.example' | ||
version = '0.0.1-SNAPSHOT' | ||
sourceCompatibility = '1.8' | ||
|
||
asciidoctor { | ||
sourceDir 'src/main/asciidoc' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I reinclude this line in one the next commits (9af112a)
… but I'd like to do it using whatever convention the plugin uses instead. Note that the snippets are still not being generated for some reason, but if the snippets are manually copied into the `build/generated-snippets` folder, then this will pick them up and include them in the generated HTML.
Any ideas why gradle isn't generating the snippets? It creates the |
This is the beginning of an attempt to use Spring Initializr's Rest Docs template to start off the tutorial instead of trying to get the right configuration by hand.
I've used untainted configuration directly from start.spring.io for both Maven and Gradle.
However this attempt is not finished because I'm new to unit and mock testing in Spring and I wouldn't want to make assumptions about those parts of the tutorial. I'll keep working on this later, but would welcome suggestions or additions in the mean time.