Skip to content

Commit

Permalink
fix readthedocs
Browse files Browse the repository at this point in the history
  • Loading branch information
dbu committed Mar 22, 2024
1 parent 39f6b35 commit ccc2046
Show file tree
Hide file tree
Showing 8 changed files with 53 additions and 148 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/spellcheck.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,9 @@ jobs:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v1
uses: actions/setup-python@v5
with:
python-version: 3.7
- name: Install dependencies
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/static.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:

steps:
- name: Checkout code
uses: actions/checkout@v2
uses: actions/checkout@v4

- name: Pull in optional dependencies
run: composer require --no-update phpunit/phpunit toflar/psr6-symfony-http-cache-store:^3.0
Expand All @@ -33,7 +33,7 @@ jobs:

steps:
- name: Checkout code
uses: actions/checkout@v2
uses: actions/checkout@v4

- name: Pull in optional dependencies
run: composer require --no-update phpunit/phpunit toflar/psr6-symfony-http-cache-store:^3.0
Expand All @@ -49,7 +49,7 @@ jobs:

steps:
- name: Checkout code
uses: actions/checkout@v2
uses: actions/checkout@v4

- name: PHP-CS-Fixer
uses: docker://oskarstark/php-cs-fixer-ga
Expand Down
48 changes: 0 additions & 48 deletions doc/_static/tabs.css → doc/_static/custom.css
Original file line number Diff line number Diff line change
@@ -1,51 +1,3 @@
div.configuration-block {
position: relative;
}

div.configuration-block ul.simple {
margin-left: 38px;
}

div.configuration-block ul.simple li {
list-style: none;
float: left;
margin-left: 0;
margin-right: 1em;
padding: .2em .5em .5em .5em;
height: 38px;
background-color: #c9c9c9;
}

div.configuration-block ul.simple li.selected {
background-color: #343131;
border-bottom: none;
}

div.configuration-block ul.simple li.selected a {
color: white;
}

div.highlight-varnish3, div.highlight-varnish4 {
border: none !important;
}

div.configuration-block em {
font-style: normal;
}

div.configuration-block div {
border-top: none;
position: absolute;
left: 0;
width: 100%;
max-width: 100%;
overflow: auto;
}

div.configuration-block div div {
position: static;
}

div.highlight {
background-color: #343131 !important;
}
Expand Down
1 change: 0 additions & 1 deletion doc/_static/tabs.js

This file was deleted.

60 changes: 5 additions & 55 deletions doc/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,6 @@
lexers['varnish3'] = CLexer()
lexers['varnish4'] = CLexer()

on_rtd = os.environ.get('READTHEDOCS', None) == 'True'
if not on_rtd: # only import and set the theme if we're building docs locally
import sphinx_rtd_theme
html_theme = 'sphinx_rtd_theme'
html_theme_path = [sphinx_rtd_theme.get_html_theme_path()]

primary_domain = 'php'
highlight_language = 'php'

Expand All @@ -29,10 +23,9 @@
# coming with Sphinx (named 'sphinx.ext.*') or your custom ones.
extensions = [
'sphinx.ext.coverage',
'sphinx.ext.extlinks',
'sphinx_rtd_theme',
'sphinx_tabs.tabs',
'sphinxcontrib.phpdomain',
'sensio.sphinx.configurationblock',
'sensio.sphinx.phpcode',
'sphinxcontrib.spelling'
]

Expand Down Expand Up @@ -102,6 +95,8 @@

# -- Options for HTML output ---------------------------------------------------

html_theme = 'sphinx_rtd_theme'

# Theme options are theme-specific and customize the look and feel of a theme
# further. For a list of options available for each theme, see the
# documentation.
Expand Down Expand Up @@ -132,12 +127,8 @@
# so a file named "default.css" will overwrite the builtin "default.css".
html_static_path = ['_static']

html_js_files = [
'tabs.js',
]

html_css_files = [
'tabs.css',
'custom.css',
'fos.css',
]

Expand Down Expand Up @@ -226,48 +217,7 @@
# If false, no module index is generated.
#latex_domain_indices = True


# -- Options for manual page output --------------------------------------------

# One entry per manual page. List of tuples
# (source start file, name, description, authors, manual section).
man_pages = [
('index', 'foshttpcache', 'FOSHttpCache Documentation',
['David Buchmann, David de Boer'], 1)
]

# If true, show URL addresses after external links.
#man_show_urls = False


# -- Options for Texinfo output ------------------------------------------------

# Grouping the document tree into Texinfo files. List of tuples
# (source start file, target name, title, author,
# dir menu entry, description, category)
texinfo_documents = [
('index', 'FOSHttpCache', 'FOSHttpCache Documentation',
'David Buchmann, David de Boer', 'FOSHttpCache', 'One line description of project.',
'Miscellaneous'),
]

# Documents to append as an appendix to all manuals.
#texinfo_appendices = []

# If false, no module index is generated.
#texinfo_domain_indices = True

# How to display URL addresses: 'footnote', 'no', or 'inline'.
#texinfo_show_urls = 'footnote'

rst_epilog = """
.. _FOSHttpCacheBundle: https://github.com/FriendsOfSymfony/FOSHttpCacheBundle
.. _GitHub: https://github.com/FriendsOfSymfony/FOSHttpCache
"""

extlinks = {'source': ('https://github.com/FriendsOfSymfony/FOSHttpCache/blob/master/%s', '') }

config_block = {
'varnish3': 'Varnish 3',
'varnish4': 'Varnish 4 - 6'
}
2 changes: 1 addition & 1 deletion doc/fastly-configuration.rst
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
.. _fastly configuration:

Fastly Configuration
-------------------
--------------------

Caching is enabled by default. All requests that are marked as cacheable will be cached.

Expand Down
9 changes: 3 additions & 6 deletions doc/requirements.txt
Original file line number Diff line number Diff line change
@@ -1,8 +1,5 @@
sphinx==1.8.5
git+https://github.com/fabpot/sphinx-php.git
sphinx-rtd-theme==1.0.0
sphinx
sphinx-rtd-theme
sphinx-tabs
sphinxcontrib-spelling
sphinxcontrib-phpdomain
pyenchant
docutils==0.17.1
jinja2<3.1.0
Loading

0 comments on commit ccc2046

Please sign in to comment.