Skip to content

Commit 34ebb7e

Browse files
committed
Documentation spelling CI
1 parent e61d360 commit 34ebb7e

10 files changed

+41
-6
lines changed

.travis.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,13 +34,16 @@ before_script:
3434
- sh -c "if [ '$TRAVIS_PHP_VERSION' = 'hhvm' ]; then ./tests/ci/install-apache-hhvm.sh; fi"
3535
# Install deps
3636
- composer update --dev --prefer-source
37+
# Install enchant
38+
- sudo apt-get install -qq enchant
3739
# Install Sphinx
3840
- sudo apt-get install python-sphinx
3941
- sudo pip install -r doc/requirements.txt
4042

4143
script:
4244
- phpunit --coverage-clover=coverage.clover
4345
- make -C doc SPHINXOPTS='-nW' html
46+
- make -C doc spelling
4447

4548
after_script:
4649
- wget https://scrutinizer-ci.com/ocular.phar

doc/Makefile

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@ help:
3737
@echo " changes to make an overview of all changed/added/deprecated items"
3838
@echo " linkcheck to check all external links for integrity"
3939
@echo " doctest to run all doctests embedded in the documentation (if enabled)"
40+
@echo " spelling generate a spelling report"
4041

4142
clean:
4243
-rm -rf $(BUILDDIR)/*
@@ -151,3 +152,7 @@ doctest:
151152
$(SPHINXBUILD) -b doctest $(ALLSPHINXOPTS) $(BUILDDIR)/doctest
152153
@echo "Testing of doctests in the sources finished, look at the " \
153154
"results in $(BUILDDIR)/doctest/output.txt."
155+
156+
spelling:
157+
$(SPHINXBUILD) -b spelling $(ALLSPHINXOPTS) $(BUILDDIR)/spelling
158+
@echo "Spelling report generated in $(BUILDDIR)/spelling/output.txt"

doc/cache-invalidator.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ caching proxy::
100100

101101
$cacheInvalidator->invalidateRegex('.*css$')->flush();
102102

103-
To invalidate all .png files on host example.com::
103+
To invalidate all ``.png`` files on host example.com::
104104

105105
$cacheInvalidator
106106
->invalidateRegex('.*', 'image/png', array('example.com'))

doc/conf.py

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,16 @@
2727

2828
# Add any Sphinx extension module names here, as strings. They can be extensions
2929
# coming with Sphinx (named 'sphinx.ext.*') or your custom ones.
30-
extensions = ['sphinx.ext.coverage', 'sphinx.ext.extlinks', 'sensio.sphinx.configurationblock']
30+
extensions = [
31+
'sphinx.ext.coverage',
32+
'sphinx.ext.extlinks',
33+
'sensio.sphinx.configurationblock',
34+
'sphinxcontrib.spelling'
35+
]
36+
37+
# Spelling configuration
38+
spelling_lang='en_US'
39+
spelling_word_list_filename='spelling_word_list.txt'
3140

3241
# Add any paths that contain templates here, relative to this directory.
3342
templates_path = ['_templates']

doc/installation.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ This library mainly consists of:
3737
* test classes that you can use for integration testing your application
3838
against a caching proxy.
3939

40-
Measures have been taken to minimise the performance impact of sending
40+
Measures have been taken to minimize the performance impact of sending
4141
invalidation requests:
4242

4343
* Requests are not sent immediately, but aggregated to be sent in parallel.

doc/proxy-clients.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -153,7 +153,7 @@ You can invalidate all URLs matching a regular expression by using the
153153
for the path to invalidate and an optional content type regular expression and
154154
list of application hostnames.
155155

156-
For instance, to ban all .png files on all application hosts::
156+
For instance, to ban all ``.png`` files on all application hosts::
157157

158158
$client->banPath('.*png$');
159159

doc/requirements.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,4 @@
11
git+https://github.com/fabpot/sphinx-php.git
22
sphinx-rtd-theme==0.1.6
3+
sphinxcontrib-spelling
4+
pyenchant

doc/spelling_word_list.txt

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
admin
2+
backend
3+
cacheable
4+
config
5+
css
6+
hostname
7+
hostnames
8+
http
9+
invalidator
10+
localhost
11+
nginx
12+
roundtrip
13+
symfony
14+
whitelisted
15+
paywall
16+
paywalls

doc/symfony-cache-configuration.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -165,7 +165,7 @@ Cleaning the Cookie Header
165165

166166
By default, the UserContextSubscriber only sets the session cookie (according to
167167
the ``session_name_prefix`` option) in the requests to the backend. If you need
168-
a different behaviour, overwrite ``UserContextSubscriber::cleanupHashLookupRequest``
168+
a different behavior, overwrite ``UserContextSubscriber::cleanupHashLookupRequest``
169169
with your own logic.
170170

171171
.. _HttpCache: http://symfony.com/doc/current/book/http_cache.html#symfony-reverse-proxy

doc/testing-your-application.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ The FOSHttpCache library provides base test case classes to help you write
1010
functional tests. This may be helpful to test the way your application sets
1111
caching headers and invalidates cached content.
1212

13-
By having your test classes extend one of the testCase classes, you get:
13+
By having your test classes extend one of the test case classes, you get:
1414

1515
* independent tests: all previously cached content is removed in the tests
1616
``setUp`` method. The way this is done depends on which reverse proxy you use;

0 commit comments

Comments
 (0)