Skip to content
This repository has been archived by the owner on Apr 7, 2023. It is now read-only.

Commit

Permalink
Version 0.0.1
Browse files Browse the repository at this point in the history
  • Loading branch information
Sergio Ferraresi committed Oct 9, 2018
1 parent 106c48c commit 39b61cb
Show file tree
Hide file tree
Showing 10 changed files with 754 additions and 3 deletions.
2 changes: 1 addition & 1 deletion LICENSE
Expand Up @@ -186,7 +186,7 @@
same "printed page" as the copyright notice for easier
identification within third-party archives.

Copyright [yyyy] [name of copyright owner]
Copyright 2018 Sergio Ferraresi

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
Expand Down
1 change: 1 addition & 0 deletions MANIFEST.in
@@ -0,0 +1 @@
include README.md LICENSE
57 changes: 55 additions & 2 deletions README.md
@@ -1,2 +1,55 @@
# pyops
OpenSearch python client
pyops: OpenSearch made easy
===========================

OpenSearch python client.

Examples:
```python
# simple example
>>> import pyops
>>> client = pyops.Client(repository_desx="https://example.org")
>>> raw_results = client.search()

# advanced search
>>> raw_results = client.search(params={"{eop:instrument?}": {"value": "SAR"}})

# advandced results filtering
>>> entry_fields = client.get_available_fields()
>>> filtered_results = client.filter_entries([{
>>> "tag": "{http://www.w3.org/2005/Atom}id",
>>> "name": "id"
>>> }, {
>>> "tag": "{http://www.w3.org/2005/Atom}title",
>>> "name": "title"
>>> }, {
>>> "tag": "{http://www.w3.org/2005/Atom}summary",
>>> "name": "summary"
>>> }, {
>>> "tag": "{http://www.w3.org/2005/Atom}published",
>>> "name": "published"
>>> }, {
>>> "tag": "{http://www.w3.org/2005/Atom}updated",
>>> "name": "updated"
>>> }, {
>>> "tag": "{http://www.w3.org/2005/Atom}link",
>>> "name": "link",
>>> "rel": "enclosure"
>>> }])
```

TODO
----
- APIs (search, ...)
- documentation

[HOW TO] DEPLOY
---------------
Update `pyops.__version__.py`
```bash
# create packages
python3 setup.py sdist bdist_wheel
# upload on test.pypi
twine upload --repository-url https://test.pypi.org/legacy/ dist/*
# test install
python3 -m pip install --index-url https://test.pypi.org/simple/ pyops
```
1 change: 1 addition & 0 deletions pyops/__init__.py
@@ -0,0 +1 @@
from .core import Client
3 changes: 3 additions & 0 deletions pyops/__version__.py
@@ -0,0 +1,3 @@
VERSION = (0, 0, 1)

__version__ = '.'.join(map(str, VERSION))

0 comments on commit 39b61cb

Please sign in to comment.