From 5839d48bb38dd611e462569d52bb7a3159129826 Mon Sep 17 00:00:00 2001 From: Santos Gallegos Date: Tue, 9 Jun 2020 14:44:14 -0500 Subject: [PATCH 1/2] Prepare 0.1.0rc1 release --- README.rst | 20 +++++++++++--------- docs/conf.py | 2 +- docs/index.rst | 37 +------------------------------------ setup.py | 17 ++++++++++++++--- sphinx_search/__init__.py | 2 +- tests/__init__.py | 2 -- tests/conftest.py | 2 -- tests/test_extension.py | 2 -- tests/test_ui.py | 2 -- tests/utils.py | 2 -- 10 files changed, 28 insertions(+), 60 deletions(-) diff --git a/README.rst b/README.rst index 6da12e1..2646850 100644 --- a/README.rst +++ b/README.rst @@ -1,17 +1,20 @@ readthedocs-sphinx-search ========================= -|docs| |license| |build-status| +|pypi| |docs| |license| |build-status| -Sphinx extension to enable `search as you type` feature for docs hosted by Read the Docs. +`Sphinx`_ extension to enable *search as you type* within a full-page search UI for docs hosted on `Read the Docs`_. +Try it at https://readthedocs-sphinx-search.readthedocs.io/en/latest/?rtd_search=testing. +.. _Sphinx: https://www.sphinx-doc.org/ +.. _Read the Docs: https://readthedocs.org/ Installation ------------ :: - pip install git+https://github.com/readthedocs/readthedocs-sphinx-search@master + pip install readthedocs-sphinx-search Configuration @@ -27,12 +30,6 @@ Add this extension in your ``conf.py`` file as: ] -Documentation -------------- - -Check out the full documentation at https://readthedocs-sphinx-search.readthedocs.io/ - - .. |docs| image:: https://readthedocs.org/projects/readthedocs-sphinx-search/badge/?version=latest :alt: Documentation Status :scale: 100% @@ -45,3 +42,8 @@ Check out the full documentation at https://readthedocs-sphinx-search.readthedoc .. |build-status| image:: https://travis-ci.org/readthedocs/readthedocs-sphinx-search.svg?branch=master :alt: Build Status :target: https://travis-ci.org/readthedocs/readthedocs-sphinx-search + + +.. |pypi| image:: https://img.shields.io/pypi/v/readthedocs-sphinx-search.svg + :target: https://pypi.python.org/pypi/readthedocs-sphinx-search + :alt: PyPI Version diff --git a/docs/conf.py b/docs/conf.py index 8d1c2a0..f228101 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -27,7 +27,7 @@ # The short X.Y version # The full version, including alpha/beta/rc tags import sphinx_search -version = release = sphinx_search.version +version = release = sphinx_search.__version__ # -- General configuration --------------------------------------------------- diff --git a/docs/index.rst b/docs/index.rst index 1a2875e..030fe9d 100644 --- a/docs/index.rst +++ b/docs/index.rst @@ -1,22 +1,4 @@ -readthedocs-sphinx-search -========================= - -|docs| |license| |build-status| - -``readthedocs-sphinx-search`` is a `Sphinx`_ extension which adds a -**full-page search UI** with **search as you type** feature to your documentation. -This extension is compatible with all the documentations hosted on `Read the Docs`_. - - -In-Doc Search UI ----------------- - -Using the existing search backend of `Read the Docs`_, -this extension is designed to greatly improve the search experience -of the reader. -To experience it first hand, try searching in this documentation or visit here: -https://readthedocs-sphinx-search.readthedocs.io/en/latest/?rtd_search=testing - +.. include:: ../README.rst .. toctree:: :maxdepth: 2 @@ -30,20 +12,3 @@ https://readthedocs-sphinx-search.readthedocs.io/en/latest/?rtd_search=testing testing js-api-reference get-involved - - -.. _Sphinx: https://www.sphinx-doc.org/ -.. _Read the Docs: https://readthedocs.org - - -.. |docs| image:: https://readthedocs.org/projects/readthedocs-sphinx-search/badge/?version=latest - :alt: Documentation Status - :target: https://readthedocs-sphinx-search.readthedocs.io/en/latest/?badge=latest - -.. |license| image:: https://img.shields.io/github/license/readthedocs/readthedocs-sphinx-search.svg - :target: LICENSE - :alt: Repository license - -.. |build-status| image:: https://travis-ci.org/readthedocs/readthedocs-sphinx-search.svg?branch=master - :alt: Build Status - :target: https://travis-ci.org/readthedocs/readthedocs-sphinx-search diff --git a/setup.py b/setup.py index f24d0b1..b67817e 100644 --- a/setup.py +++ b/setup.py @@ -1,16 +1,18 @@ import setuptools + import sphinx_search with open('README.rst', 'r') as fh: long_description = fh.read() + setuptools.setup( - name='readthedocs_sphinx_search', - version=sphinx_search.version, + name='readthedocs-sphinx-search', + version=sphinx_search.__version__, author='Vaibhav Gupta', author_email='vaibhgupt199@gmail.com', - description='Sphinx extension to enable `search as you type` for docs hosted by Read the Docs.', + description='Sphinx extension to enable search as you type for docs hosted on Read the Docs.', url='https://github.com/readthedocs/readthedocs-sphinx-search', license='MIT', packages=setuptools.find_packages(), @@ -18,9 +20,18 @@ long_description_content_type='text/x-rst', include_package_data=True, zip_safe=False, + keywords='sphinx search readthedocs', + python_requires='>=3.6', + project_urls={ + 'Documentation': 'https://readthedocs-sphinx-search.readthedocs.io/', + 'Bug Reports': 'https://github.com/readthedocs/readthedocs-sphinx-search/issues', + 'Source': 'https://github.com/readthedocs/readthedocs-sphinx-search', + }, classifiers=[ + 'Development Status :: 4 - Beta', 'Programming Language :: Python :: 3', 'License :: OSI Approved :: MIT License', 'Operating System :: OS Independent', + 'Framework :: Sphinx :: Extension', ], ) diff --git a/sphinx_search/__init__.py b/sphinx_search/__init__.py index 8776766..226dd5f 100644 --- a/sphinx_search/__init__.py +++ b/sphinx_search/__init__.py @@ -1 +1 @@ -version = '0.1.dev0' \ No newline at end of file +__version__ = '0.1.0rc1' diff --git a/tests/__init__.py b/tests/__init__.py index 1d9b61b..c65b2a2 100644 --- a/tests/__init__.py +++ b/tests/__init__.py @@ -1,5 +1,3 @@ -# -*- coding: utf-8 -*- - import os diff --git a/tests/conftest.py b/tests/conftest.py index 9df1cc0..300c28d 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -1,5 +1,3 @@ -# -*- coding: utf-8 -*- - """Pytest fixtures and other things.""" import os diff --git a/tests/test_extension.py b/tests/test_extension.py index 97cc903..bcbca24 100644 --- a/tests/test_extension.py +++ b/tests/test_extension.py @@ -1,5 +1,3 @@ -# -*- coding: utf-8 -*- - """Test working of extension.""" import os diff --git a/tests/test_ui.py b/tests/test_ui.py index 528f733..37c8407 100644 --- a/tests/test_ui.py +++ b/tests/test_ui.py @@ -1,5 +1,3 @@ -# -*- coding: utf-8 -*- - """UI tests.""" import os diff --git a/tests/utils.py b/tests/utils.py index 32fa9d5..c3239fd 100644 --- a/tests/utils.py +++ b/tests/utils.py @@ -1,5 +1,3 @@ -# -*- coding: utf-8 -*- - """Utils for testing.""" import os From b1796ff36b2d1d871c9590e16a8554b6f82fa459 Mon Sep 17 00:00:00 2001 From: Santos Gallegos Date: Tue, 9 Jun 2020 15:17:53 -0500 Subject: [PATCH 2/2] Fix tests --- README.rst | 1 - scripts/setup_chromedriver.sh | 2 +- tox.ini | 2 +- 3 files changed, 2 insertions(+), 3 deletions(-) diff --git a/README.rst b/README.rst index 2646850..6ae31e5 100644 --- a/README.rst +++ b/README.rst @@ -32,7 +32,6 @@ Add this extension in your ``conf.py`` file as: .. |docs| image:: https://readthedocs.org/projects/readthedocs-sphinx-search/badge/?version=latest :alt: Documentation Status - :scale: 100% :target: https://readthedocs-sphinx-search.readthedocs.io/en/latest/?badge=latest .. |license| image:: https://img.shields.io/github/license/readthedocs/readthedocs-sphinx-search.svg diff --git a/scripts/setup_chromedriver.sh b/scripts/setup_chromedriver.sh index 29b5c64..7851c20 100644 --- a/scripts/setup_chromedriver.sh +++ b/scripts/setup_chromedriver.sh @@ -1,4 +1,4 @@ -wget -N https://chromedriver.storage.googleapis.com/81.0.4044.69/chromedriver_linux64.zip -P ~/ +wget -N https://chromedriver.storage.googleapis.com/83.0.4103.39/chromedriver_linux64.zip -P ~/ unzip ~/chromedriver_linux64.zip -d ~/ rm ~/chromedriver_linux64.zip sudo mv -f ~/chromedriver /usr/local/bin/ diff --git a/tox.ini b/tox.ini index 1156392..6dda190 100644 --- a/tox.ini +++ b/tox.ini @@ -10,7 +10,7 @@ skipsdist = True description = run the whole test suite deps = . - pytest-selenium + pytest-selenium==1.17.0 sphinx18: Sphinx<1.9 sphinx20: Sphinx<2.1 sphinx21: Sphinx<2.2