Skip to content

Commit 499e329

Browse files
authored
Merge pull request #19 from urlstechie/add/readme-note-manual-run
Adding note to readme for how to do manual run
2 parents f21f0c7 + 42d25e6 commit 499e329

2 files changed

Lines changed: 18 additions & 95 deletions

File tree

README.md

Lines changed: 18 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -267,16 +267,32 @@ https://github.com/SuperKogito/URLs-checker/issues/1,failed
267267
https://github.com/SuperKogito/URLs-checker/issues/4,failed
268268
```
269269
270-
If you have any questions, please don't hesitate to [open an issue](https://github.com/urlstechie/urlchecker-python).
271270
271+
### Usage from Python
272+
273+
If you want to check a list of urls outside of the provided client, this is fairly easy to do!
274+
Let's say we have a list of urls, `urls`:
275+
276+
```python
277+
from urlchecker.core.urlproc import check_urls
278+
279+
# We will update a dictionary with failed and passed
280+
check_results = {"failed": [], "passed": []}
281+
check_urls(urls=urls, retry_count=3, timeout=5, check_results=check_results)
282+
```
283+
284+
Using the above, you're check_results will be updated to include those in your
285+
list that passed, and those that failed.
286+
287+
If you have any questions, please don't hesitate to [open an issue](https://github.com/urlstechie/urlchecker-python).
272288
273289
### Docker
274290
275291
A Docker container is provided if you want to build a base container with urlchecker,
276292
meaning that you don't need to install it on your host. You can build the container as
277293
follows:
278294
279-
```bsah
295+
```bash
280296
docker build -t urlchecker .
281297
```
282298

urlchecker/client/github.py

Lines changed: 0 additions & 93 deletions
This file was deleted.

0 commit comments

Comments
 (0)