From: Filipe Brandenburger Date: Wed, 2 Jan 2019 22:20:39 +0000 (-0800) Subject: docs: generate index.md in Jekyll X-Git-Tag: v241-rc1~121^2 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=357211a4260e47d5ea24db2a8062d263d58ec791;p=thirdparty%2Fsystemd.git docs: generate index.md in Jekyll This uses a {% for %} loop in Jekyll to render the page, from the "title" information in the Front Matter of the actual page files. This also makes `make-index-md` build rule unnecessary, since generation is done by the template engine itself. Tested this by running Jekyll locally. --- diff --git a/docs/index.md b/docs/index.md index 890c4f8e767..ffb30b9634c 100644 --- a/docs/index.md +++ b/docs/index.md @@ -4,21 +4,8 @@ title: systemd Documentation # systemd Documentation -* [Automatic Boot Assessment](https://systemd.io/AUTOMATIC_BOOT_ASSESSMENT) -* [Locking Block Device Access](https://systemd.io/BLOCK_DEVICE_LOCKING) -* [The Boot Loader Interface](https://systemd.io/BOOT_LOADER_INTERFACE) -* [The Boot Loader Specification](https://systemd.io/BOOT_LOADER_SPECIFICATION) -* [Control Group APIs and Delegation](https://systemd.io/CGROUP_DELEGATION) -* [The systemd Community Conduct Guidelines](https://github.com/systemd/systemd/blob/master/docs/CODE_OF_CONDUCT.md) -* [Code Quality Tools](https://systemd.io/CODE_QUALITY) -* [Coding Style](https://systemd.io/CODING_STYLE) -* [Contributing](https://github.com/systemd/systemd/blob/master/docs/CONTRIBUTING.md) -* [Porting systemd To New Distributions](https://systemd.io/DISTRO_PORTING) -* [Predictable Network Interface Names](https://systemd.io/PREDICTABLE_INTERFACE_NAMES) -* [Known Environment Variables](https://systemd.io/ENVIRONMENT) -* [Hacking on systemd](https://systemd.io/HACKING) -* [Portable Services Introduction](https://systemd.io/PORTABLE_SERVICES) -* [Steps to a Successful Release](https://systemd.io/RELEASE) -* [What settings are currently available for transient units?](https://systemd.io/TRANSIENT-SETTINGS) -* [Notes for Translators](https://systemd.io/TRANSLATORS) -* [Users, Groups, UIDs and GIDs on `systemd` Systems](https://systemd.io/UIDS-GIDS) +{% for p in site.pages %} + {% if p.url != page.url and p.title %} +* [{{ p.title }}]({{ p.url | relative_url }}) + {% endif %} +{% endfor %} diff --git a/meson.build b/meson.build index f74a0bf3b2d..b4af6a790cd 100644 --- a/meson.build +++ b/meson.build @@ -3050,10 +3050,6 @@ run_target( depends : [man, libsystemd, libudev], command : [meson_check_api_docs_sh, libsystemd.full_path(), libudev.full_path()]) -run_target( - 'make-index-md', - command : ['sh', '@0@/tools/make-index-md.sh'.format(meson.source_root()), meson.source_root()]) - ############################################################ status = [ diff --git a/tools/make-index-md.sh b/tools/make-index-md.sh deleted file mode 100755 index 78506cbf396..00000000000 --- a/tools/make-index-md.sh +++ /dev/null @@ -1,32 +0,0 @@ -#!/bin/sh - -set -eu - -cd "$@"/docs/ -( - echo -e "# systemd Documentation\n" - - for f in *.md ; do - if [ "x$f" != "xindex.md" ] ; then - t=`grep "^# " "$f" | head -n 1 | sed -e 's/^#\s*//'` - - if [ "x$f" = "xCODE_OF_CONDUCT.md" -o "x$f" = "xCONTRIBUTING.md" ] ; then - # For some reason GitHub refuses to generate - # HTML versions of these two documents, - # probably because they are in some way special - # in GitHub behaviour (as they are shown as - # links in the issue submission form). Let's - # work around this limitation by linking to - # their repository browser version - # instead. This might not even be such a bad - # thing, given that the issue submission form - # and our index file thus link to the same - # version. - u="https://github.com/systemd/systemd/blob/master/docs/$f" - else - u="https://systemd.io/"`echo "$f" | sed -e 's/.md$//'` - fi - echo "* [$t]($u)" - fi - done -) > index.md