Skip to content

Commit a7db138

Browse files
committed
Merge branch 'master' into davidfischer/storage-epubs-pdfs-zips
2 parents 03787f4 + 39a0d5f commit a7db138

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

80 files changed

+1079
-1030
lines changed

.pyup.yml

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
# configure updates globally
2+
# default: all
3+
# allowed: all, insecure, False
4+
update: all
5+
6+
# configure dependency pinning globally
7+
# default: True
8+
# allowed: True, False
9+
pin: True
10+
11+
# update schedule
12+
# default: empty
13+
# allowed: "every day", "every week", ..
14+
schedule: "every week"
15+
16+
# search for requirement files
17+
# default: True
18+
# allowed: True, False
19+
search: True
20+
21+
# configure the branch prefix the bot is using
22+
# default: pyup-
23+
branch_prefix: pyup/
24+
25+
# set a global prefix for PRs
26+
# default: empty
27+
pr_prefix: "pyup: "
28+
29+
# allow to close stale PRs
30+
# default: True
31+
close_prs: True

CHANGELOG.rst

Lines changed: 80 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,83 @@
1+
Version 3.2.2
2+
-------------
3+
4+
:Date: February 13, 2019
5+
6+
* `@ericholscher <http://github.com/ericholscher>`__: Support old jquery where responseJSON doesn't exist (`#5285 <https://github.com/rtfd/readthedocs.org/pull/5285>`__)
7+
* `@humitos <http://github.com/humitos>`__: pyup.yml syntax fixed (`#5284 <https://github.com/rtfd/readthedocs.org/pull/5284>`__)
8+
* `@dojutsu-user <http://github.com/dojutsu-user>`__: Fix error of travis (rename migration file) (`#5282 <https://github.com/rtfd/readthedocs.org/pull/5282>`__)
9+
* `@humitos <http://github.com/humitos>`__: pyup YAML configuration file (`#5279 <https://github.com/rtfd/readthedocs.org/pull/5279>`__)
10+
* `@pyup-bot <http://github.com/pyup-bot>`__: Pin ipdb to latest version 0.11 (`#5278 <https://github.com/rtfd/readthedocs.org/pull/5278>`__)
11+
* `@pyup-bot <http://github.com/pyup-bot>`__: Pin datadiff to latest version 2.0.0 (`#5277 <https://github.com/rtfd/readthedocs.org/pull/5277>`__)
12+
* `@pyup-bot <http://github.com/pyup-bot>`__: Pin pytest-cov to latest version 2.6.1 (`#5276 <https://github.com/rtfd/readthedocs.org/pull/5276>`__)
13+
* `@pyup-bot <http://github.com/pyup-bot>`__: Pin pillow to latest version 5.4.1 (`#5275 <https://github.com/rtfd/readthedocs.org/pull/5275>`__)
14+
* `@pyup-bot <http://github.com/pyup-bot>`__: Update elasticsearch to 6.3.1 (`#5274 <https://github.com/rtfd/readthedocs.org/pull/5274>`__)
15+
* `@discdiver <http://github.com/discdiver>`__: clarify github integration needs https:// prepended (`#5273 <https://github.com/rtfd/readthedocs.org/pull/5273>`__)
16+
* `@humitos <http://github.com/humitos>`__: Setup and configure pyup.io (`#5272 <https://github.com/rtfd/readthedocs.org/pull/5272>`__)
17+
* `@humitos <http://github.com/humitos>`__: Update all Python dependencies (`#5269 <https://github.com/rtfd/readthedocs.org/pull/5269>`__)
18+
* `@davidfischer <http://github.com/davidfischer>`__: Add note about security issue (`#5263 <https://github.com/rtfd/readthedocs.org/pull/5263>`__)
19+
* `@ericholscher <http://github.com/ericholscher>`__: Don’t delay search delete on project delete (`#5262 <https://github.com/rtfd/readthedocs.org/pull/5262>`__)
20+
* `@agjohnson <http://github.com/agjohnson>`__: Automate docs version from our setup.cfg (`#5259 <https://github.com/rtfd/readthedocs.org/pull/5259>`__)
21+
* `@agjohnson <http://github.com/agjohnson>`__: Add admin actions for building versions (`#5255 <https://github.com/rtfd/readthedocs.org/pull/5255>`__)
22+
* `@ericholscher <http://github.com/ericholscher>`__: Give the 404 page a title. (`#5252 <https://github.com/rtfd/readthedocs.org/pull/5252>`__)
23+
* `@humitos <http://github.com/humitos>`__: Make our SUFFIX default selection py2/3 compatible (`#5251 <https://github.com/rtfd/readthedocs.org/pull/5251>`__)
24+
* `@ericholscher <http://github.com/ericholscher>`__: Release 3.2.1 (`#5248 <https://github.com/rtfd/readthedocs.org/pull/5248>`__)
25+
* `@ericholscher <http://github.com/ericholscher>`__: Remove excluding files on search. (`#5246 <https://github.com/rtfd/readthedocs.org/pull/5246>`__)
26+
* `@gorshunovr <http://github.com/gorshunovr>`__: Change version references to :latest tag (`#5245 <https://github.com/rtfd/readthedocs.org/pull/5245>`__)
27+
* `@humitos <http://github.com/humitos>`__: Remove py2 compatibility (`#5241 <https://github.com/rtfd/readthedocs.org/pull/5241>`__)
28+
* `@stsewd <http://github.com/stsewd>`__: Allow to override trigger_build from demo project (`#5236 <https://github.com/rtfd/readthedocs.org/pull/5236>`__)
29+
* `@ericholscher <http://github.com/ericholscher>`__: Change some info logging to debug to clean up build output (`#5233 <https://github.com/rtfd/readthedocs.org/pull/5233>`__)
30+
* `@stsewd <http://github.com/stsewd>`__: Fake auth middleware in tests (`#5206 <https://github.com/rtfd/readthedocs.org/pull/5206>`__)
31+
* `@EJEP <http://github.com/EJEP>`__: Clarify 'more info' link in admin settings page (`#5180 <https://github.com/rtfd/readthedocs.org/pull/5180>`__)
32+
* `@rexzing <http://github.com/rexzing>`__: Docs reformatting with :guilabel: (`#5161 <https://github.com/rtfd/readthedocs.org/pull/5161>`__)
33+
34+
Version 3.2.1
35+
-------------
36+
37+
:Date: February 07, 2019
38+
39+
* `@ericholscher <http://github.com/ericholscher>`__: Remove excluding files on search. (`#5246 <https://github.com/rtfd/readthedocs.org/pull/5246>`__)
40+
* `@ericholscher <http://github.com/ericholscher>`__: Don't update search on HTMLFile save (`#5244 <https://github.com/rtfd/readthedocs.org/pull/5244>`__)
41+
* `@ericholscher <http://github.com/ericholscher>`__: Be more defensive in our 404 handler (`#5243 <https://github.com/rtfd/readthedocs.org/pull/5243>`__)
42+
* `@humitos <http://github.com/humitos>`__: Install sphinx-notfound-page for building 404.html custom page (`#5242 <https://github.com/rtfd/readthedocs.org/pull/5242>`__)
43+
* `@humitos <http://github.com/humitos>`__: Remove py2 compatibility (`#5241 <https://github.com/rtfd/readthedocs.org/pull/5241>`__)
44+
* `@ericholscher <http://github.com/ericholscher>`__: Release 3.2.0 (`#5240 <https://github.com/rtfd/readthedocs.org/pull/5240>`__)
45+
46+
Version 3.2.0
47+
-------------
48+
49+
:Date: February 06, 2019
50+
51+
* `@ericholscher <http://github.com/ericholscher>`__: Support passing an explicit `index_name` for search indexing (`#5239 <https://github.com/rtfd/readthedocs.org/pull/5239>`__)
52+
* `@davidfischer <http://github.com/davidfischer>`__: Tweak some ad styles (`#5237 <https://github.com/rtfd/readthedocs.org/pull/5237>`__)
53+
* `@stsewd <http://github.com/stsewd>`__: Fix conda issue link (`#5226 <https://github.com/rtfd/readthedocs.org/pull/5226>`__)
54+
* `@humitos <http://github.com/humitos>`__: Add Santos to the development team (`#5224 <https://github.com/rtfd/readthedocs.org/pull/5224>`__)
55+
* `@ericholscher <http://github.com/ericholscher>`__: Update our GSOC page for 2019 (`#5210 <https://github.com/rtfd/readthedocs.org/pull/5210>`__)
56+
* `@humitos <http://github.com/humitos>`__: Do not allow to merge 'Status: blocked' PRs (`#5205 <https://github.com/rtfd/readthedocs.org/pull/5205>`__)
57+
* `@stsewd <http://github.com/stsewd>`__: Inject user to middleware tests (`#5203 <https://github.com/rtfd/readthedocs.org/pull/5203>`__)
58+
* `@ericholscher <http://github.com/ericholscher>`__: Remove approvals requirement from mergable (`#5200 <https://github.com/rtfd/readthedocs.org/pull/5200>`__)
59+
* `@agjohnson <http://github.com/agjohnson>`__: Update project notification copy to past tense (`#5199 <https://github.com/rtfd/readthedocs.org/pull/5199>`__)
60+
* `@stsewd <http://github.com/stsewd>`__: Remove feature flag for v2 (`#5198 <https://github.com/rtfd/readthedocs.org/pull/5198>`__)
61+
* `@ericholscher <http://github.com/ericholscher>`__: Refactor search code (`#5197 <https://github.com/rtfd/readthedocs.org/pull/5197>`__)
62+
* `@stsewd <http://github.com/stsewd>`__: Update mergeable settings to v2 (`#5196 <https://github.com/rtfd/readthedocs.org/pull/5196>`__)
63+
* `@stsewd <http://github.com/stsewd>`__: Fix mergeable bot (`#5195 <https://github.com/rtfd/readthedocs.org/pull/5195>`__)
64+
* `@stsewd <http://github.com/stsewd>`__: Fix broken links for badges (`#5190 <https://github.com/rtfd/readthedocs.org/pull/5190>`__)
65+
* `@dojutsu-user <http://github.com/dojutsu-user>`__: Change badge style (`#5189 <https://github.com/rtfd/readthedocs.org/pull/5189>`__)
66+
* `@humitos <http://github.com/humitos>`__: Allow source_suffix to be a dictionary (`#5183 <https://github.com/rtfd/readthedocs.org/pull/5183>`__)
67+
* `@humitos <http://github.com/humitos>`__: Upgrade all packages removing py2 compatibility (`#5179 <https://github.com/rtfd/readthedocs.org/pull/5179>`__)
68+
* `@dojutsu-user <http://github.com/dojutsu-user>`__: Small docs fix (`#5176 <https://github.com/rtfd/readthedocs.org/pull/5176>`__)
69+
* `@stsewd <http://github.com/stsewd>`__: Sync all services even if one social accoun fails (`#5171 <https://github.com/rtfd/readthedocs.org/pull/5171>`__)
70+
* `@ericholscher <http://github.com/ericholscher>`__: Release 3.1.0 (`#5170 <https://github.com/rtfd/readthedocs.org/pull/5170>`__)
71+
* `@rvmzes <http://github.com/rvmzes>`__: SyntaxError caused by comma in python3 (`#5156 <https://github.com/rtfd/readthedocs.org/pull/5156>`__)
72+
* `@humitos <http://github.com/humitos>`__: Use latest docker images as default (`#5155 <https://github.com/rtfd/readthedocs.org/pull/5155>`__)
73+
* `@stsewd <http://github.com/stsewd>`__: Remove logic for guessing slug from an unregistered domain (`#5143 <https://github.com/rtfd/readthedocs.org/pull/5143>`__)
74+
* `@humitos <http://github.com/humitos>`__: Allow custom 404.html on projects (`#5130 <https://github.com/rtfd/readthedocs.org/pull/5130>`__)
75+
* `@dojutsu-user <http://github.com/dojutsu-user>`__: Docs for feature flag (`#5043 <https://github.com/rtfd/readthedocs.org/pull/5043>`__)
76+
* `@stsewd <http://github.com/stsewd>`__: Remove usage of project.documentation_type in tasks (`#4896 <https://github.com/rtfd/readthedocs.org/pull/4896>`__)
77+
* `@ericholscher <http://github.com/ericholscher>`__: Reapply the Elastic Search upgrade to `master` (`#4722 <https://github.com/rtfd/readthedocs.org/pull/4722>`__)
78+
* `@stsewd <http://github.com/stsewd>`__: Config file v2 docs (`#4451 <https://github.com/rtfd/readthedocs.org/pull/4451>`__)
79+
* `@stsewd <http://github.com/stsewd>`__: Set python3 as default interpreter (`#3581 <https://github.com/rtfd/readthedocs.org/pull/3581>`__)
80+
181
Version 3.1.0
282
-------------
383

docs/advertising/ethical-advertising.rst

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -154,15 +154,14 @@ or a `Supporter <https://readthedocs.org/sustainability/#donations>`_.
154154

155155
Users can opt out of seeing paid advertisements on documentation pages:
156156

157-
* Go to the drop down user menu in the top right of the Read the Docs dashboard and clicking **Settings** (https://readthedocs.org/accounts/edit/).
158-
* On the **Advertising** tab, you can deselect **See paid advertising**.
157+
* Go to the drop down user menu in the top right of the Read the Docs dashboard and clicking :guilabel:`Settings` (https://readthedocs.org/accounts/edit/).
158+
* On the :guilabel:`Advertising` tab, you can deselect **See paid advertising**.
159159

160160
Project owners can also opt out of paid advertisements for their projects.
161161
You can change these options:
162162

163-
* Click on your **Project** page (`/projects/<slug>/`)
164-
* Click the **Admin** dashboard link
165-
* Choose the **Advertising** submenu on the left side
163+
* Go to your **project** page (`/projects/<slug>/`)
164+
* Go to :guilabel:`Admin` > :guilabel:`Advertising`
166165
* Change your advertising settings
167166

168167
Project opt out options include:

docs/builds.rst

Lines changed: 3 additions & 53 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ if you provide a good reason your documentation needs more resources.
1818
You can see the current Docker build images that we use in our `docker repository <https://github.com/rtfd/readthedocs-docker-images>`_.
1919
`Docker Hub <https://hub.docker.com/r/readthedocs/build/>`_ also shows the latest set of images that have been built.
2020

21-
Currently in production we're using the ``readthedocs/build:2.0`` docker image as our default image.
21+
Currently in production we're using the ``readthedocs/build:latest`` docker image as our default image.
2222

2323
How we build documentation
2424
--------------------------
@@ -118,7 +118,7 @@ The build environment
118118
---------------------
119119

120120
The build process is executed inside Docker containers,
121-
by default the image used is ``readthedocs/build:2.0``,
121+
by default the image used is ``readthedocs/build:latest``,
122122
but you can change that using a :doc:`config-file/index`.
123123

124124
.. note::
@@ -133,57 +133,7 @@ but you can change that using a :doc:`config-file/index`.
133133
If you want to know the specific version of a package that is installed in the image
134134
you can check the `Ubuntu package search page <https://packages.ubuntu.com/>`__.
135135

136-
2.0 (stable)
137-
~~~~~~~~~~~~
138-
139-
:O.S: Ubuntu 16.04
140-
:Conda: Miniconda 4.3.31
141-
:Python:
142-
* ``m2crypto``
143-
* ``matplolib``
144-
* ``numpy``
145-
* ``pandas``
146-
* ``pip``
147-
* ``scipy``
148-
:Other packages:
149-
* ``doxygen``
150-
* ``graphviz``
151-
* ``libevent``
152-
* ``libjpeg``
153-
* ``libxml2-dev``
154-
* ``libxslt1.1``
155-
* ``pandoc``
156-
* ``textlive-full``
157-
158-
`More details <https://github.com/rtfd/readthedocs-docker-images/blob/releases/2.x/Dockerfile>`__
159-
160-
3.0 (latest)
161-
~~~~~~~~~~~~
162-
163-
:O.S: Ubuntu 16.04
164-
:Conda: Miniconda 4.4.10
165-
:Python:
166-
* ``matplolib``
167-
* ``numpy``,
168-
* ``pandas``
169-
* ``pip``
170-
* ``scipy``
171-
:JavaScript:
172-
* ``jsdoc``
173-
* ``nodejs``
174-
* ``npm``
175-
:Other packages:
176-
* ``doxygen``
177-
* ``libevent-dev``
178-
* ``libgraphviz-dev``
179-
* ``libjpeg``
180-
* ``libxml2-dev``
181-
* ``libxslt1-dev``
182-
* ``pandoc``
183-
* ``plantuml``
184-
* ``textlive-full``
185-
186-
`More details <https://github.com/rtfd/readthedocs-docker-images/blob/releases/3.x/Dockerfile>`__
136+
More details on software installed in images could be found by browsing specific branch in `rtfd/readthedocs-docker-images <https://github.com/rtfd/readthedocs-docker-images>`__ repository.
187137

188138
Writing your own builder
189139
------------------------

docs/canonical.rst

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,15 +15,18 @@ Example
1515

1616
Fabric hosts their docs on Read the Docs.
1717
They mostly use their own domain for them ``http://docs.fabfile.org``.
18-
This means that Google will index both ``http://fabric-docs.readthedocs.io`` and ``http://docs.fabfile.org`` for their documentation.
18+
This means that Google will index both ``http://fabric-docs.readthedocs.io`` and
19+
``http://docs.fabfile.org`` for their documentation.
1920

2021
Fabric will want to set ``http://docs.fabfile.org`` as their canonical URL.
21-
This means that when Google indexes ``http://fabric-docs.readthedocs.io``, it will know that it should really point at ``http://docs.fabfile.org``.
22+
This means that when Google indexes ``http://fabric-docs.readthedocs.io``,
23+
it will know that it should really point at ``http://docs.fabfile.org``.
2224

2325
Enabling
2426
--------
2527

26-
You can set the canonical URL for your project in the Project Admin page. Check your `Domains` tab for the domains that we know about.
28+
You can set the canonical URL for your project in the Project Admin page.
29+
Check your :guilabel:`Admin` > :guilabel:`Domains` page for the domains that we know about.
2730

2831
Implementation
2932
--------------

docs/commercial/custom_domains.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,8 @@ you can still host with us.
1919
We require two steps from your side:
2020

2121
* Add a CNAME record in your DNS that points to our servers ``<organization-slug>.users.readthedocs.com``
22-
* Set your project's Privacy Level to *Public* from **Project Admin > Advance Settings**.
23-
* Add a Domain in the **Project Admin > Domains** page for your project.
22+
* Set your project's Privacy Level to *Public* from :guilabel:`Admin` > :guilabel:`Advance Settings`.
23+
* Add a Domain in the :guilabel:`Admin` > :guilabel:`Domains` page for your project.
2424

2525
.. note:: The domain that should be used is the actual subdomain that you want your docs served on.
2626
Generally it will be ``docs.projectname.com``.

docs/conf.py

Lines changed: 23 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44

55
import os
66
import sys
7+
from configparser import RawConfigParser
78

89
import sphinx_rtd_theme
910

@@ -18,6 +19,13 @@
1819
django.setup()
1920

2021

22+
def get_version():
23+
"""Return package version from setup.cfg."""
24+
config = RawConfigParser()
25+
config.read(os.path.join('..', 'setup.cfg'))
26+
return config.get('metadata', 'version')
27+
28+
2129
sys.path.append(os.path.abspath('_ext'))
2230
extensions = [
2331
'sphinx.ext.autosectionlabel',
@@ -29,6 +37,7 @@
2937
'sphinx_tabs.tabs',
3038
'sphinx-prompt',
3139
'recommonmark',
40+
'notfound.extension',
3241
]
3342
templates_path = ['_templates']
3443

@@ -39,7 +48,7 @@
3948
copyright = '2010-{}, Read the Docs, Inc & contributors'.format(
4049
timezone.now().year
4150
)
42-
version = '2.7'
51+
version = get_version()
4352
release = version
4453
exclude_patterns = ['_build']
4554
default_role = 'obj'
@@ -81,6 +90,19 @@
8190
# Activate autosectionlabel plugin
8291
autosectionlabel_prefix_document = True
8392

93+
# sphinx-notfound-page
94+
# https://github.com/rtfd/sphinx-notfound-page
95+
notfound_context = {
96+
'title': 'Page Not Found',
97+
'body': '''
98+
<h1>Page Not Found</h1>
99+
100+
<p>Sorry, we couldn't find that page.</p>
101+
102+
<p>Try using the search box or go to the homepage.</p>
103+
''',
104+
}
105+
84106

85107
def setup(app):
86108
app.add_stylesheet('css/sphinx_prompt_css.css')

docs/config-file/v1.rst

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -112,8 +112,8 @@ The ``build`` block configures specific aspects of the documentation build.
112112
build.image
113113
```````````
114114

115-
* Default: :djangosetting:`DOCKER_IMAGE`
116-
* Options: ``1.0``, ``2.0``, ``latest``
115+
* Default: :djangosetting:`DOCKER_DEFAULT_VERSION`
116+
* Options: ``stable``, ``latest``
117117

118118
The build image to use for specific builds.
119119
This lets users specify a more experimental build image,
@@ -122,9 +122,8 @@ if they want to be on the cutting edge.
122122
Certain Python versions require a certain build image,
123123
as defined here:
124124

125-
* ``1.0``: 2, 2.7, 3, 3.4
126-
* ``2.0``: 2, 2.7, 3, 3.5
127-
* ``latest``: 2, 2.7, 3, 3.3, 3.4, 3.5, 3.6
125+
* ``stable``: :buildpyversions:`stable`
126+
* ``latest``: :buildpyversions:`latest`
128127

129128
.. code-block:: yaml
130129
@@ -147,8 +146,8 @@ used for building documentation.
147146
python.version
148147
``````````````
149148

150-
* Default: ``2.7``
151-
* Options: ``2.7``, ``2``, ``3.5``, ``3``
149+
* Default: ``3.7``
150+
* Options: :buildpyversions:`latest`
152151

153152
This is the version of Python to use when building your documentation.
154153
If you specify only the major version of Python,
@@ -158,7 +157,7 @@ the highest supported minor version will be selected.
158157

159158
The supported Python versions depends on the version of the build image your
160159
project is using. The default build image that is used to build
161-
documentation contains support for Python ``2.7`` and ``3.5``. See the
160+
documentation contains support for Python ``2.7`` and ``3.7``. See the
162161
:ref:`yaml__build__image` for more information on supported Python versions.
163162

164163
.. code-block:: yaml

docs/contribute.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ We have a strict code style that is easy to follow since you just have to
4747
install `pre-commit`_ and it will automatically run different linting tools
4848
(`autoflake`_, `autopep8`_, `docformatter`_, `isort`_, `prospector`_, `unify`_
4949
and `yapf`_) to check your changes before you commit them. `pre-commit` will let
50-
you know if there were any problems that is wasn't able to fix automatically.
50+
you know if there were any problems that it wasn't able to fix automatically.
5151

5252
To run the `pre-commit` command and check your changes:
5353

docs/custom_installs/local_rtd_vm.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -160,7 +160,7 @@ Log into ``http://[VM IP ADDRESS]:[PORT]`` using the django superuser creds and
160160
For a new project
161161
`````````````````
162162

163-
1. Select **<username> > Add Project** from the user menu.
163+
1. Select :guilabel:`<username>` > :guilabel:`Add Project` from the user menu.
164164
2. Click **Manually Import Project**.
165165
3. Provide the following information in the **Project Details** page:
166166

@@ -174,7 +174,7 @@ For a new project
174174
For an existing project
175175
```````````````````````
176176

177-
1. Select **<username> > Projects** from the user menu.
177+
1. Select :guilabel:`<username>` > :guilabel:`Projects` from the user menu.
178178
2. Select the relevant project from the **Projects** list.
179179
3. Select latest from the **Build a version** dropdown.
180180
4. Click **Build**. This will take you to the Builds tab where the progress status is displayed. This may take some time.

0 commit comments

Comments
 (0)