Skip to content

Commit c5542d4

Browse files
authored
Merge pull request #68 from wpyoga/docs-develop
Add notes for development environment
2 parents bf306e7 + 819aa47 commit c5542d4

File tree

1 file changed

+20
-4
lines changed

1 file changed

+20
-4
lines changed

README.md

Lines changed: 20 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@
33
WS-Discovery in Python
44
======================
55
This is WS-Discovery implementation for Python 3. It allows to both discover
6-
services and publish discoverable services. For Python 2 support, use the latest 1.x version
7-
of this package.
6+
services and publish discoverable services. For Python 2 support, use the
7+
latest 1.x version of this package.
88

99
Extensive [package documentation is available at ReadTheDocs](https://python-ws-discovery.readthedocs.io).
1010

@@ -13,9 +13,12 @@ Install from PyPI: `pip install WSDiscovery`.
1313
Basic usage
1414
------------
1515

16-
A simple `wsdiscover` command-line client is provided for discovering WS-Discovery compliant devices and systems. Run `wsdiscover --help` for usage instructions.
16+
A simple `wsdiscover` command-line client is provided for discovering
17+
WS-Discovery compliant devices and systems. Run `wsdiscover --help` for
18+
usage instructions.
1719

18-
Here's an example of how to use the package in your Python code. The following code first publishes a service and then discovers it:
20+
Here's an example of how to use the package in your Python code. The following
21+
code first publishes a service and then discovers it:
1922

2023
```python
2124
from wsdiscovery.discovery import ThreadedWSDiscovery as WSDiscovery
@@ -41,6 +44,19 @@ Here's an example of how to use the package in your Python code. The following c
4144
wsd.stop()
4245
```
4346

47+
Development notes
48+
-----------------
49+
To fix a bug or develop this package, it is recommended to use a virtual
50+
environment and set up a development environment. For example:
51+
```
52+
$ python3 -m venv venv
53+
$ . venv/bin/activate
54+
(venv) $ pip3 install -e
55+
```
56+
Then you can call `wsdiscover` and `wspublish` from within this virtual
57+
environment. Any code changes to the package will be available and testable
58+
immediately.
59+
4460
Development state
4561
-----------------
4662
This is not 100% complete and correct WS-Discovery implementation. It doesn't

0 commit comments

Comments
 (0)