File tree Expand file tree Collapse file tree 5 files changed +36
-37
lines changed
Expand file tree Collapse file tree 5 files changed +36
-37
lines changed Original file line number Diff line number Diff line change 3737 podman run -v $PWD:/srv:z --workdir /srv/_build --rm rpm sh -c \
3838 "cmake .. && make man-html"
3939
40- # sed -i 's|<b>\(rpm[^<]*\)</b>(\(.\))|<a href="\1.\2.html">\1(\2)</a>|g' docs/man/rpm*.html
41- mv _build/docs/man/*.html docs/man/
42- ls docs/man/*.html
40+ mv _build/docs/man/{*.html,index.md} docs/man/
4341
4442 - name : Setup Pages
4543 id : pages
Original file line number Diff line number Diff line change @@ -21,6 +21,7 @@ add_custom_target(man ALL DEPENDS ${manuals})
2121
2222set (manuals-html ${manuals} )
2323list (TRANSFORM manuals-html APPEND .html)
24+ configure_file (index.sh index.sh @ONLY )
2425configure_file (post.sh post.sh @ONLY )
2526foreach (man ${manuals} )
2627 add_custom_command (OUTPUT ${man} .html
@@ -30,7 +31,8 @@ foreach(man ${manuals})
3031 COMMAND ./post.sh ${man} .html
3132 DEPENDS ${man} .scd )
3233endforeach ()
33- add_custom_target (man-html ALL DEPENDS ${manuals-html} )
34+ add_custom_command (OUTPUT index.md COMMAND ./index.sh )
35+ add_custom_target (man-html ALL DEPENDS ${manuals-html} index.md )
3436
3537# Install manuals for the enabled features
3638set (manuals ${core} )
Load Diff This file was deleted.
Original file line number Diff line number Diff line change 1+ #! /bin/bash
2+
3+ BLAH=" \
4+ ---
5+ layout: default
6+ title: rpm.org - RPM Manual Pages
7+ ---
8+ # RPM Manual Pages
9+
10+ ## Tools"
11+
12+ add_item () {
13+ file=$( basename $1 )
14+ link=$( echo " $file " | sed ' s/.scd$/.html/' )
15+ name=$( echo " $file " | sed ' s/^\(.\+\)\.\(.\+\)\.scd$/\1(\2)/' )
16+ echo " * [$name ]($link )"
17+ }
18+
19+ echo " $BLAH " > index.md
20+
21+ find @CMAKE_CURRENT_SOURCE_DIR@ -name " *.scd" ! -name " rpm-plugin-*" | sort | \
22+ while read file; do
23+ add_item $file >> index.md
24+ done
25+
26+ echo -e " \n## Plugins" >> index.md
27+
28+ find @CMAKE_CURRENT_SOURCE_DIR@ -name " rpm-plugin-*.scd" | sort | \
29+ while read file; do
30+ add_item $file >> index.md
31+ done
Original file line number Diff line number Diff line change @@ -9,4 +9,5 @@ title: rpm.org - $NAME
99---
1010"
1111cat <( echo " $FRONT_MATTER " ) $1 > $1 .tmp
12+ sed -i ' s|<b>\(rpm[^<]*\)</b>(\(.\))|<a href="\1.\2.html">\1(\2)</a>|g' $1 .tmp
1213mv $1 .tmp $1
You can’t perform that action at this time.
0 commit comments