Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
S
spring-cloud-netflix
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
openSource
spring-cloud-netflix
Commits
9cab69a9
Commit
9cab69a9
authored
Jun 11, 2016
by
Dave Syer
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update readme script to handle local includes
parent
243c13b7
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
3 deletions
+10
-3
generate_readme.sh
docs/src/main/ruby/generate_readme.sh
+10
-3
No files found.
docs/src/main/ruby/generate_readme.sh
View file @
9cab69a9
...
...
@@ -16,9 +16,16 @@ end
file
=
ARGV[0]
if
ARGV.length>0
srcDir
=
File.dirname
(
file
)
out
=
"// Do not edit this file (e.g. go instead to docs/src/main/asciidoc)
\n\n
"
doc
=
Asciidoctor.load_file file, safe: :safe, parse:
false
, attributes:
'allow-uri-read'
# Copied from https://github.com/asciidoctor/asciidoctor-extensions-lab/blob/master/scripts/asciidoc-coalescer.rb
doc
=
Asciidoctor.load_file file, safe: :unsafe, header_only:
true
, attributes: options[:attributes]
header_attr_names
=
(
doc.instance_variable_get :@attributes_modified
)
.to_a
header_attr_names.each
{
|k| doc.attributes[%
(
#{k}!)] = '' unless doc.attr? k }
attrs
=
doc.attributes
attrs[
'allow-uri-read'
]
=
true
puts attrs
out
=
"// Do not edit this file (e.g. go instead to src/main/asciidoc)
\n\n
"
doc
=
Asciidoctor.load_file file, safe: :unsafe, parse:
false
, attributes: attrs
out
<<
doc
.reader.read
unless options[:to_file]
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment