Skip to content

Commit

Permalink
Specification: rework of how the spec is generated, and link fix (ope…
Browse files Browse the repository at this point in the history
  • Loading branch information
chalin authored Feb 17, 2022
1 parent 3a41958 commit 253da40
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 8 deletions.
5 changes: 0 additions & 5 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,6 @@ tmp/
scripts/collector.yaml
assets/jsconfig.json

# Generated content
/content/en/docs/reference/specification/**/*.md
/content/en/docs/reference/specification/**/*.png
!/content/en/docs/reference/specification/_index.md

# IntelliJ
*.iml

Expand Down
2 changes: 2 additions & 0 deletions config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -146,6 +146,8 @@ params:

module:
mounts:
- source: tmp/specification
target: content/docs/reference/specification
- source: content/en
target: content
- source: static
Expand Down
1 change: 1 addition & 0 deletions scripts/adjust-spec-pages.pl
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,7 @@ ()
s|(/semantic_conventions/faas.md)#function-as-a-service|$1|g;
s/#log-data-model/./;

s|\.\.\/README.md\b|..| if $ARGV =~ /specification.library-guidelines.md/;
s|\bREADME.md\b|_index.md|g;

# Rewrite inline links
Expand Down
6 changes: 3 additions & 3 deletions scripts/cp-spec-pages.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@

BASE_DIR=$(dirname $0)
SPEC=content-modules/opentelemetry-specification/specification
DEST=content/en/docs/reference/specification

git clean -xdf $DEST > /dev/null
DEST=tmp/specification

rm -Rf $DEST
mkdir -p $DEST
cp -R $SPEC/* $DEST/

find $DEST/ -name "README.md" -exec sh -c 'f="{}"; mv -- "$f" "${f%README.md}_index.md"' \;
Expand Down

0 comments on commit 253da40

Please sign in to comment.