Skip to content

Commit

Permalink
Merge pull request #27 from SmartContractSecurity/docs
Browse files Browse the repository at this point in the history
Added the logic to preview documentation with read-docs
  • Loading branch information
s0b0lev authored Jan 4, 2019
2 parents fb5d6ec + 9338c8d commit 81dd356
Show file tree
Hide file tree
Showing 2 changed files with 43 additions and 1 deletion.
4 changes: 3 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@


[![CircleCI](https://circleci.com/gh/SmartContractSecurity/SWC-registry-python.svg?style=svg)](https://circleci.com/gh/SmartContractSecurity/SWC-registry-python)
[![Documentation Status](https://readthedocs.org/projects/swc-registry-python/badge/?version=latest)](https://swc-registry-python.readthedocs.io/en/latest/?badge=latest)


## Description
Python library for accessing SWC-registry content.
Expand Down Expand Up @@ -36,4 +38,4 @@ print(swc.title)

// Function Default Visibility
```
## Contribution
## Contribution
40 changes: 40 additions & 0 deletions docs/index.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
Getting Started with swc-registry-python
========================================

SWC-registry-python is a python package for accessing SWC-registry content.


Quick start
-----------

Assuming you have Python already:

.. sourcecode:: bash

$ pip install swc-registry

Check the package work:

.. sourcecode:: python

from swc_registry import SWC

swc = SWC('SWC-100')
print(swc.title)

// Function Default Visibility


Get the latest content of SWC-registry
--------------------------------------

On first use of the SWC methods, the SWC registry is initialized from file (swc-definition.json) out cache. If user wants to get the latest information about SWC-registry he needs to pass the second argument of SWC class.

.. sourcecode:: python

from swc_registry import SWC

swc = SWC('SWC-100', True)
print(swc.title)

// Function Default Visibility

0 comments on commit 81dd356

Please sign in to comment.