|
2 | 2 | {% load i18n %}
|
3 | 3 |
|
4 | 4 | {% block project_add_content_subheader %}
|
5 |
| -{% trans "Add a configuration file (<code>.readthedocs.yaml</code>) to your project" %} |
| 5 | + {% trans "Add a configuration file to your project" %} |
6 | 6 | {% endblock project_add_content_subheader %}
|
7 | 7 |
|
8 |
| -{% block project_add_css_classes %}ui ten wide tablet wide computer column{% endblock project_add_css_classes %} |
9 |
| -{% block project_add_content_main %} |
10 |
| -<p class="info"> |
| 8 | +{% block project_add_content_classes %}ui fourteen wide tablet twelve wide computer column{% endblock %} |
| 9 | + |
| 10 | +{% block project_add_content_form %} |
| 11 | + <div class="ui small info message"> |
11 | 12 | {% blocktrans trimmed %}
|
12 |
| - Make sure your project has a <code>.readthedocs.yaml</code> at the root of your repository. This file is required by Read the Docs to be able to build your documentation. You can <a href="https://docs.readthedocs.io/en/stable/config-file/v2.html">read more about this in our documentation</a>. |
| 13 | + A <code>.readthedocs.yaml</code> configuration file is required at the root of your repository in order to build your documentation. |
13 | 14 | {% endblocktrans %}
|
14 |
| -</p> |
| 15 | + |
| 16 | + <a href="https://docs.readthedocs.io/page/config-file/index.html" target="_blank"> |
| 17 | + {% trans "Learn how to add a configuration file to your project." %} |
| 18 | + </a> |
| 19 | + </div> |
| 20 | + |
| 21 | + <div class="ui basic fitted right aligned segment"> |
| 22 | + <span>{% trans "Example configuration for:" %}</span> |
| 23 | + <div class="ui inline dropdown" data-bind="semanticui: { dropdown: {}}"> |
| 24 | + <input type="hidden" name="tool" value="sphinx"> |
| 25 | + <span class="text">Sphinx</span> |
| 26 | + <i class="dropdown icon"></i> |
| 27 | + <div class="menu"> |
| 28 | + <div class="item" data-value="sphinx">Sphinx</div> |
| 29 | + |
| 30 | + {% comment %} |
| 31 | + Adding a second option here will require a bit of JS or FUI: |
| 32 | + https://github.com/readthedocs/ext-theme/issues/184 |
| 33 | + {% endcomment %} |
15 | 34 |
|
16 |
| -<p class="info"> |
17 |
| - Here you have an example for a common Sphinx project: |
| 35 | + {# The `actionable` class here prevents the select from selecting the text #} |
| 36 | + <a class="actionable item" href="https://docs.readthedocs.io/page/config-file/index.html#getting-started-with-a-template" target="_blank"> |
| 37 | + {% trans "See more examples" %} |
| 38 | + </a> |
| 39 | + </div> |
| 40 | + </div> |
| 41 | + </div> |
18 | 42 |
|
19 |
| - <pre class="ui padded"> |
20 |
| - <code class="ui small text"> |
21 |
| -# .readthedocs.yaml |
| 43 | + <div class="ui mini padded inverted scrolling segment"> |
| 44 | + <div class="ui top attached label"> |
| 45 | + <code>.readthedocs.yaml</code> |
| 46 | + </div> |
| 47 | + <a class="ui top right attached icon label" href="#" data-clipboard-target="#project-create-sample-sphinx"> |
| 48 | + <i class="fas fa-copy icon"></i> |
| 49 | + </a> |
| 50 | + <code class="highlight"> |
| 51 | + <pre id="project-create-sample-sphinx"> |
22 | 52 | # Read the Docs configuration file
|
23 | 53 | # See https://docs.readthedocs.io/en/stable/config-file/v2.html for details
|
24 | 54 |
|
25 | 55 | # Required
|
26 | 56 | version: 2
|
27 | 57 |
|
28 |
| -# Set the OS, Python version and other tools you might need |
| 58 | +# Set the OS, Python version, and other tools you might need |
29 | 59 | build:
|
30 | 60 | os: ubuntu-22.04
|
31 | 61 | tools:
|
|
50 | 80 | # python:
|
51 | 81 | # install:
|
52 | 82 | # - requirements: docs/requirements.txt
|
53 |
| - </code> |
54 |
| - </pre> |
55 |
| -</p> |
| 83 | + </pre> |
| 84 | + </code> |
| 85 | + </div> |
| 86 | + |
| 87 | + {# Show the base form #} |
| 88 | + {{ block.super }} |
56 | 89 |
|
57 |
| -{{ block.super }} |
58 |
| -{% endblock project_add_content_main %} |
| 90 | +{% endblock project_add_content_form %} |
59 | 91 |
|
60 |
| -{% block project_add_help_topics %} |
61 |
| -{% endblock project_add_help_topics %} |
| 92 | +{% block project_add_sidebar_help_topics %} |
| 93 | + {% include "includes/elements/link.html" with url="https://docs.readthedocs.io/page/config-file/index.html" text="Configuration file tutorial" is_external=True class="item" %} |
| 94 | + {% include "includes/elements/link.html" with url="https://docs.readthedocs.io/page/config-file/v2.html" text="Configuration file reference" is_external=True class="item" %} |
| 95 | + {% include "includes/elements/link.html" with url="https://docs.readthedocs.io/page/guides/setup/git-repo-manual.html" text="Manually configuring a Git repository" is_external=True class="item" %} |
| 96 | +{% endblock project_add_sidebar_help_topics %} |
0 commit comments