Skip to content

Commit

Permalink
Fix images in example docs (#2630)
Browse files Browse the repository at this point in the history
  • Loading branch information
charlesbvll authored Nov 23, 2023
1 parent bd8c0e0 commit 01fdba4
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 2 deletions.
9 changes: 7 additions & 2 deletions dev/update-examples.sh
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,14 @@ cd examples/
for d in $(printf '%s\n' */ | sort -V); do
example=${d%/}
# For each example, copy the README into the source of the Example docs
[[ $example = doc ]] || cp $example/README.md $ROOT/examples/doc/source/$example.md 2>&1 >/dev/null
[[ $example != doc ]] && cp $example/README.md $ROOT/examples/doc/source/$example.md 2>&1 >/dev/null
# For each example, copy all images of the _static folder into the examples
# docs static folder
[[ $example != doc ]] && [ -d "$example/_static" ] && {
cp $example/_static/**.{jpg,png,jpeg} $ROOT/examples/doc/source/_static/ 2>/dev/null || true
}
# For each example, insert the name of the example into the index file
[[ $example = doc ]] || (echo $INSERT_LINE; echo a; echo $example; echo .; echo wq) | ed $INDEX 2>&1 >/dev/null
[[ $example != doc ]] && (echo $INSERT_LINE; echo a; echo $example; echo .; echo wq) | ed $INDEX 2>&1 >/dev/null
done

echo "\`\`\`" >> $INDEX
Expand Down
5 changes: 5 additions & 0 deletions examples/doc/source/_static/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
*
!custom.css
!favicon.ico
!flower-logo.png
!tmux_jtop_view.gif
Binary file removed examples/doc/source/_static/diagram.png
Binary file not shown.

0 comments on commit 01fdba4

Please sign in to comment.