From 3e5ad768743ded1417e750ed266d4646db3ede97 Mon Sep 17 00:00:00 2001 From: Robert de Bock Date: Tue, 31 Mar 2020 07:37:43 +0200 Subject: [PATCH] Use hashes for titles. --- templates/README.md.j2 | 37 ++++++++++++------------------------- 1 file changed, 12 insertions(+), 25 deletions(-) diff --git a/templates/README.md.j2 b/templates/README.md.j2 index a8fd996..7de0c90 100644 --- a/templates/README.md.j2 +++ b/templates/README.md.j2 @@ -1,5 +1,4 @@ -{{ role_name }} -========= +# {{ role_name }} {{ meta.galaxy_info.description }} @@ -7,8 +6,7 @@ |------|------|-------|---------| |[![travis](https://travis-ci.com/{{ travis_namespace }}/ansible-role-{{ role_name }}.svg?branch=master)](https://travis-ci.com/{{ travis_namespace }}/ansible-role-{{ role_name }})|[![github](https://github.com/{{ github_namespace }}/ansible-role-{{ role_name }}/workflows/Ansible%20Molecule/badge.svg)](https://github.com/{{ github_namespace }}/ansible-role-{{ role_name }}/actions)|[![quality](https://img.shields.io/ansible/quality/{{ galaxy_id.stdout }})](https://galaxy.ansible.com/{{ github_namespace }}/{{ role_name }})|[![downloads](https://img.shields.io/ansible/role/d/{{ galaxy_id.stdout }})](https://galaxy.ansible.com/{{ github_namespace }}/{{ role_name }})| -Example Playbook ----------------- +## Example Playbook This example is taken from `molecule/resources/converge.yml` and is tested on each push, pull request and release. ```yaml @@ -32,16 +30,14 @@ For verification `molecule/resources/verify.yml` run after the role has been app Also see a [full explanation and example](https://robertdebock.nl/how-to-use-these-roles.html) on how to use these roles. {% if variables.content is defined %} -Role Variables --------------- +## Role Variables These variables are set in `defaults/main.yml`: ```yaml {{ variables.content | b64decode }}``` {% endif %} -Requirements ------------- +## Requirements - Access to a repository containing packages, likely on the internet. - A recent version of Ansible. (Tests run on the current, previous and next release of Ansible.) @@ -53,8 +49,7 @@ The following roles can be installed to ensure all requirements are met, using ` ``` {% if meta.dependencies %} -Dependencies ------------- +## Dependencies Most roles require some kind of preparation, this is done in `molecule/default/prepare.yml`. This role has a "hard" dependency on the following roles: @@ -62,17 +57,14 @@ Most roles require some kind of preparation, this is done in `molecule/default/p - {{ dependency }} {% endfor %} {% endif %} -Context -------- +## Context This role is a part of many compatible roles. Have a look at [the documentation of these roles](https://robertdebock.nl/) for further information. Here is an overview of related roles: ![dependencies](https://raw.githubusercontent.com/{{ github_namespace }}/drawings/artifacts/{{ role_name }}.png "Dependency") - -Compatibility -------------- +## Compatibility This role has been tested on these [container images](https://hub.docker.com/): @@ -89,8 +81,7 @@ The minimum version of Ansible required is {{ meta.galaxy_info.min_ansible_versi - The development version. {% if exceptions is defined %} -Exceptions ----------- +## Exceptions Some variarations of the build matrix do not work. These are the variations and reasons why the build won't work: @@ -100,8 +91,7 @@ Some variarations of the build matrix do not work. These are the variations and {% endfor %}{% endif %} {% if versions is defined %} -Included version(s) -------------------- +## Included version(s) This role [refers to a version]({{ reference }}) released by {{ project_name }}. Check the released version(s) here: {% for version in versions %} @@ -110,8 +100,7 @@ This role [refers to a version]({{ reference }}) released by {{ project_name }}. This version reference means a role may get outdated. Monthly tests occur to see if [bit-rot](https://en.wikipedia.org/wiki/Software_rot) occured. If you however find a problem, please create an issue, I'll get on it as soon as possible.{% endif %} -Testing -------- +## Testing [Unit tests](https://travis-ci.com/{{ travis_namespace }}/ansible-role-{{ role_name }}) are done on every commit, pull request, release and periodically. @@ -145,13 +134,11 @@ image="centos" tox image="debian" tag="stable" tox ``` -License -------- +## License {{ meta.galaxy_info.license }} -Author Information ------------------- +## Author Information [{{ meta.galaxy_info.author }}]({{ author_website }})