Skip to content

Commit 9f88cab

Browse files
committed
fix rst formatting issues in readme, remove python compat section, add link to docs
Signed-off-by: oleg.hoefling <oleg.hoefling@gmail.com>
1 parent 194028b commit 9f88cab

File tree

1 file changed

+79
-93
lines changed

1 file changed

+79
-93
lines changed

README.rst

Lines changed: 79 additions & 93 deletions
Original file line numberDiff line numberDiff line change
@@ -15,26 +15,34 @@ python-xmlsec
1515
:target: https://xmlsec.readthedocs.io/en/latest/?badge=latest
1616
:alt: Documentation Status
1717

18-
Python bindings for the XML Security Library.
18+
Python bindings for the `XML Security Library <https://www.aleksey.com/xmlsec/>`_.
19+
20+
Documentation
21+
*************
22+
23+
A documentation for ``xmlsec`` can be found at `xmlsec.readthedocs.io <https://xmlsec.readthedocs.io/>`_.
1924

20-
******
2125
Usage
22-
******
26+
*****
2327

24-
Check the `examples <http://pythonhosted.org/xmlsec/examples.html>`_ to see various examples of signing and verifying using the library.
28+
Check the `examples <https://xmlsec.readthedocs.io/en/latest/examples.html>`_ section in the documentation to see various examples of signing and verifying using the library.
2529

26-
************
2730
Requirements
2831
************
29-
- libxml2 >= 2.9.1
30-
- libxmlsec1 >= 1.2.14
32+
- ``libxml2 >= 2.9.1``
33+
- ``libxmlsec1 >= 1.2.18``
3134

32-
*******
3335
Install
3436
*******
3537

36-
Pre-Install
37-
-----------
38+
``xmlsec`` is available on PyPI:
39+
40+
.. code-block:: bash
41+
42+
pip install xmlsec
43+
44+
Prerequisites
45+
-------------
3846

3947
Linux (Debian)
4048
^^^^^^^^^^^^^^
@@ -44,105 +52,90 @@ Linux (Debian)
4452
apt-get install libxml2-dev libxmlsec1-dev libxmlsec1-openssl
4553
4654
47-
Note: There is no required version of libxml2 for ubuntu precise,
48-
so need to download and install it manually.
55+
Note: There is no required version of LibXML2 for Ubuntu Precise,
56+
so you need to download and install it manually.
4957

5058
.. code-block:: bash
5159
52-
wget http://xmlsoft.org/sources/libxml2-2.9.1.tar.gz
53-
tar -xvf libxml2-2.9.1.tar.gz
54-
cd libxml2-2.9.1
55-
./configure && make && make install
60+
wget http://xmlsoft.org/sources/libxml2-2.9.1.tar.gz
61+
tar -xvf libxml2-2.9.1.tar.gz
62+
cd libxml2-2.9.1
63+
./configure && make && make install
5664
5765
5866
Linux (CentOS)
5967
^^^^^^^^^^^^^^
6068

6169
.. code-block:: bash
6270
63-
yum install libxml2-devel xmlsec1-devel xmlsec1-openssl-devel libtool-ltdl-devel
71+
yum install libxml2-devel xmlsec1-devel xmlsec1-openssl-devel libtool-ltdl-devel
6472
6573
6674
Mac
6775
^^^
6876

6977
.. code-block:: bash
7078
71-
brew install libxml2 libxmlsec1 pkg-config
79+
brew install libxml2 libxmlsec1 pkg-config
7280
7381
7482
Alpine
7583
^^^^^^
7684

7785
.. code-block:: bash
7886
79-
apk add build-base libressl libffi-dev libressl-dev libxslt-dev libxml2-dev xmlsec-dev xmlsec
80-
81-
82-
Automated
83-
---------
84-
1. **xmlsec** can be installed through `easy_install` or `pip`.
85-
86-
.. code-block:: bash
87-
88-
pip install xmlsec
87+
apk add build-base libressl libffi-dev libressl-dev libxslt-dev libxml2-dev xmlsec-dev xmlsec
8988
89+
Troubleshooting
90+
---------------
9091

9192
Mac
9293
^^^
9394

94-
If you get any fatal errors about missing .h files, update your C_INCLUDE_PATH environment variable to
95-
include the appropriate files from the libxml2 and libxmlsec1 libraries.
96-
95+
If you get any fatal errors about missing ``.h`` files, update your
96+
``C_INCLUDE_PATH`` environment variable to include the appropriate
97+
files from the ``libxml2`` and ``libxmlsec1`` libraries.
9798

98-
Windows (Wheel)
99-
^^^^^^^^^^^^^^^
10099

101-
#. Download appropriate binary wheel from `ci.appveyor.com <https://ci.appveyor.com/project/bgaifullin/python-xmlsec>`_ (see build`s artifacts).
100+
Windows
101+
^^^^^^^
102102

103-
#. Install wheel
104-
105-
.. code-block:: bash
106-
107-
pip install <wheel filename>
108-
109-
110-
Windows (pip)
111-
^^^^^^^^^^^^^
103+
Starting with 1.3.7, prebuilt wheels are available for Windows,
104+
so running ``pip install xmlsec`` should suffice. If you want
105+
to build from source:
112106

113107
#. Configure build environment, see `wiki.python.org <https://wiki.python.org/moin/WindowsCompilers>`_ for more details.
114108

115-
#. Install from pip
109+
#. Install from source dist:
116110

117-
.. code-block:: bash
111+
.. code-block:: bash
118112
119-
pip install xmlsec
113+
pip install xmlsec --no-binary=xmlsec
120114
121115
122-
Manual
123-
------
116+
Building from source
117+
--------------------
124118

125-
#. Clone the **xmlsec** repository to your local computer.
119+
#. Clone the ``xmlsec`` repository to your local computer.
126120

127-
.. code-block:: bash
121+
.. code-block:: bash
128122
129-
git clone git://github.com/mehcode/python-xmlsec.git
123+
git clone https://github.com/mehcode/python-xmlsec.git
130124
131-
#. Change into the **xmlsec** root directory.
125+
#. Change into the ``python-xmlsec`` root directory.
132126

133-
.. code-block:: bash
127+
.. code-block:: bash
134128
135-
cd /path/to/xmlsec
129+
cd /path/to/xmlsec
136130
137131
138-
#. Install the project and all its dependencies using `pip`.
132+
#. Install the project and all its dependencies using ``pip``.
139133

140-
.. code-block:: bash
134+
.. code-block:: bash
141135
142-
pip install .
136+
pip install .
143137
144138
145-
************
146139
Contributing
147140
************
148141

@@ -156,66 +149,59 @@ Setting up your environment
156149
This is done so as to ensure every contributor is working with
157150
close-to-identicial versions of packages.
158151

159-
.. code-block:: bash
152+
.. code-block:: bash
153+
154+
mkvirtualenv xmlsec
155+
156+
The ``mkvirtualenv`` command is available from ``virtualenvwrapper`` package which can be installed by following `link <http://virtualenvwrapper.readthedocs.org/en/latest/install.html#basic-installation>`_.
160157

161-
mkvirtualenv xmlsec
158+
#. Activate the created virtual environment:
162159

160+
.. code-block:: bash
163161
164-
The `mkvirtualenv` command is available from `virtualenvwrapper` which
165-
can be installed by following `link <http://virtualenvwrapper.readthedocs.org/en/latest/install.html#basic-installation>`_
162+
workon xmlsec
166163
167-
#. Install **xmlsec** in development mode with testing enabled.
164+
#. Install ``xmlsec`` in development mode with testing enabled.
168165
This will download all dependencies required for running the unit tests.
169166

170-
.. code-block:: bash
167+
.. code-block:: bash
171168
172-
pip install -r requirements-test.txt
173-
pip install -e "."
169+
pip install -r requirements-test.txt
170+
pip install -e "."
174171
175172
176173
Running the test suite
177174
----------------------
178175

179-
#. [Set up your environment](#setting-up-your-environment).
176+
#. `Set up your environment <#setting-up-your-environment>`_.
180177

181178
#. Run the unit tests.
182179

183-
.. code-block:: bash
180+
.. code-block:: bash
184181
185-
py.test tests
182+
pytest tests
186183
187184
#. Tests configuration
188-
Env variable **PYXMLSEC_TEST_ITERATIONS** specifies number of test iterations to detect memory leaks.
189185

190-
Reporting a issue
191-
-----------------
192-
Please attach the output of following information:
193-
version of python-xmlsec
194-
version of libxmlsec1
195-
version of libxml2
196-
197-
output from command:
198-
199-
.. code-block:: bash
186+
Env variable ``PYXMLSEC_TEST_ITERATIONS`` specifies number of
187+
test iterations to detect memory leaks.
200188

201-
pkg-config --cflags xmlsec1
189+
Reporting an issue
190+
------------------
202191

192+
Please attach the output of following information:
203193

204-
******************
205-
Versions of python
206-
******************
194+
* version of ``xmlsec``
195+
* version of ``libxmlsec1``
196+
* version of ``libxml2``
197+
* output from the command
207198

208-
The following versions of python is supported:
199+
.. code-block:: bash
209200
210-
- python2.7
211-
- python3.4
212-
- python3.5 (required libxmlsec1 >= 1.2.18 and libxml2 >= 2.9.1)
213-
- python3.6 (required libxmlsec1 >= 1.2.18 and libxml2 >= 2.9.1)
214-
- python3.7 (required libxmlsec1 >= 1.2.18 and libxml2 >= 2.9.1)
201+
pkg-config --cflags xmlsec1
215202
216-
*******
217203
License
218204
*******
219205

220-
Unless otherwise noted, all files contained within this project are liensed under the MIT opensource license.
221-
See the included file LICENSE or visit `opensource.org <http://opensource.org/licenses/MIT>`_ for more information.
206+
Unless otherwise noted, all files contained within this project are licensed under the MIT opensource license.
207+
See the included ``LICENSE`` file or visit `opensource.org <http://opensource.org/licenses/MIT>`_ for more information.

0 commit comments

Comments
 (0)