Skip to content

Commit

Permalink
Merge branch 'feature/readthedocs_init' into 'develop'
Browse files Browse the repository at this point in the history
Feature/readthedocs init

See merge request ftubic/sevenbridges-cwl!5
  • Loading branch information
Filip Tubic committed Nov 23, 2018
2 parents 0c4dc48 + 5116684 commit 3172435
Show file tree
Hide file tree
Showing 3 changed files with 31 additions and 7 deletions.
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,8 @@ The `master` branch is for more stable code while `develop` is for cutting edge

## <a name="docs">Docs</a>

Complete documentation can be found [here](https://sevenbridges-cwl.readthedocs.io/en/latest/quickstart.html).

If you are interested in reviewing this documentation locally, clone this
repository, position yourself in the `docs` directory and after installing
`requirements-dev.txt`, invoke:
Expand Down
25 changes: 23 additions & 2 deletions docs/installation.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,25 @@
Installation
============
1. Clone
2. Redirect to sevenbridges-cwl and install: `cd sevenbridges-cwl && pip install .`
The easiest way to install sevenbridges-cwl is using pip:
```
$ pip install sevenbridges-cwl
```

Get the Code
============
Library `sevenbridges-cwl` is actively developed on GitHub.

The easiest way to obtain the source is to clone the public repository:

```
$ git clone [email protected]:sbg/sevenbridges-cwl.git
```


Once you have a copy of the source, you can embed it in your Python package,
or install it into your site-packages by invoking:

```
$ python setup.py install
```

11 changes: 6 additions & 5 deletions docs/quickstart.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,9 @@ t.add_output(cwl.File(glob='_stdout_', required=True), id='out')
```
Example above illustrates `echo HelloWorld > _stdout_` command. Object `t` is
an instance of `CommandLineTool` class which has a number of useful builtin
methods described [here](code.html#v1_0.CommandLineTool). Generated tool
can be easily run on a Seven Bridges platform using `Session` object:
methods described [here](code.html#sbg.cwl.v1_0.CommandLineTool).
Generated tool can be easily run on a Seven Bridges platform using
`Session` object:
```python
session = cwl.Session(profile='<your_profile>')
session.run('<your_project>', t)
Expand Down Expand Up @@ -178,7 +179,7 @@ Input/Output types are translated into CWL concrete types by following rules:
(eg. `cwl.Array(cwl.Int())` - list of ints)

Complete documentation of `@to_tool` decorator is located
[here](code.html#v1_0.to_tool).
[here](code.html#sbg.cwl.v1_0.to_tool).


### Wrapping bash code
Expand Down Expand Up @@ -247,7 +248,7 @@ with cwl.workflow('wf.cwl', 'w') as wf:
```

Object `wf` is an instance of `Workflow` class which documentation can be found
[here](code.html#v1_0.Workflow).
[here](code.html#sbg.cwl.v1_0.Workflow).

Running code block above will generate `wf.cwl` in the current working
directory. Using [Rabix Composer](https://github.com/rabix/composer) generated
Expand Down Expand Up @@ -302,7 +303,7 @@ session.run('<your_project>', wf, inputs={'x': '10.2', 'n': 10})
## Loading existing documents

Existing CWL documents can be loaded from a file using `load` function,
[docs](code.html?#v1_0.load).
[docs](code.html?#sbg.cwl.v1_0.load).

```python
from sbg import cwl
Expand Down

0 comments on commit 3172435

Please sign in to comment.