Browse Source

Externalize javadoc-baseurl asciidoctor attribute

The `javadoc-baseurl` asciidoctor attribute is now externalized
(i.e. not included directly in the document anymore).

This allows to properly render javadoc links in single pages, whereas
those URLs were previoulsy only supported in the single page version.
pull/759/head
Brian Clozel 11 years ago
parent
commit
7fa4ac1cf8
  1. 3
      build.gradle
  2. 4
      src/asciidoc/Guardfile
  3. 3
      src/asciidoc/index.adoc

3
build.gradle

@ -1118,7 +1118,8 @@ configure(rootProject) { @@ -1118,7 +1118,8 @@ configure(rootProject) {
separateOutputDirs = false
backends = ['docbook']
options doctype: 'book', eruby: 'erubis'
attributes 'spring-version': project.version,
attributes 'spring-version': project.version,
'javadoc-baseurl' : "http://docs.spring.io/spring/docs/current/javadoc-api",
revnumber : project.version,
docinfo : ""
}

4
src/asciidoc/Guardfile

@ -8,9 +8,9 @@ FileUtils.cp_r('images','build') @@ -8,9 +8,9 @@ FileUtils.cp_r('images','build')
guard 'shell' do
watch(/^.*\.adoc$/) {|m|
if m[0] != "index.adoc"
Asciidoctor.render_file(m[0], :to_dir => "build", :safe => Asciidoctor::SafeMode::UNSAFE, :attributes=> {'idprefix' => '', 'idseparator' => '-', 'copycss' => '', 'icons' => 'font', 'source-highlighter' => 'prettify', 'sectanchors' => '', 'doctype' => 'book', 'toc' => 'left', 'toclevels' => '2', 'spring-version' => '4.2.0.BUILD-SNAPSHOT', 'revnumber' => '4.2.0.BUILD-SNAPSHOT' })
Asciidoctor.render_file(m[0], :to_dir => "build", :safe => Asciidoctor::SafeMode::UNSAFE, :attributes=> {'idprefix' => '', 'idseparator' => '-', 'copycss' => '', 'icons' => 'font', 'source-highlighter' => 'prettify', 'sectanchors' => '', 'doctype' => 'book', 'toc' => 'left', 'toclevels' => '2', 'spring-version' => '4.2.0.BUILD-SNAPSHOT', 'revnumber' => '4.2.0.BUILD-SNAPSHOT', 'javadoc-baseurl' => "http://docs.spring.io/spring/docs/current/javadoc-api" })
end
Asciidoctor.render_file("index.adoc", :to_dir => "build", :safe => Asciidoctor::SafeMode::UNSAFE, :attributes=> {'idprefix' => '', 'idseparator' => '-', 'copycss' => '', 'icons' => 'font', 'source-highlighter' => 'prettify', 'sectanchors' => '', 'doctype' => 'book', 'toc' => 'left', 'toclevels' => '1', 'spring-version' => '4.2.0.BUILD-SNAPSHOT', 'revnumber' => '4.2.0.BUILD-SNAPSHOT' })
Asciidoctor.render_file("index.adoc", :to_dir => "build", :safe => Asciidoctor::SafeMode::UNSAFE, :attributes=> {'idprefix' => '', 'idseparator' => '-', 'copycss' => '', 'icons' => 'font', 'source-highlighter' => 'prettify', 'sectanchors' => '', 'doctype' => 'book', 'toc' => 'left', 'toclevels' => '1', 'spring-version' => '4.2.0.BUILD-SNAPSHOT', 'revnumber' => '4.2.0.BUILD-SNAPSHOT', 'javadoc-baseurl' => "http://docs.spring.io/spring/docs/current/javadoc-api" })
}
end

3
src/asciidoc/index.adoc

@ -2,9 +2,6 @@ @@ -2,9 +2,6 @@
Rod Johnson; Juergen Hoeller; Keith Donald; Colin Sampaleanu; Rob Harrop; Thomas Risberg; Alef Arendsen; Darren Davison; Dmitriy Kopylenko; Mark Pollack; Thierry Templier; Erwin Vervaet; Portia Tung; Ben Hale; Adrian Colyer; John Lewis; Costin Leau; Mark Fisher; Sam Brannen; Ramnivas Laddad; Arjen Poutsma; Chris Beams; Tareq Abedrabbo; Andy Clement; Dave Syer; Oliver Gierke; Rossen Stoyanchev; Phillip Webb; Rob Winch; Brian Clozel; Stephane Nicoll; Sebastien Deleuze
:javadoc-baseurl: http://docs.spring.io/spring/docs/current/javadoc-api
include::overview.adoc[]
include::whats-new.adoc[]

Loading…
Cancel
Save