From 25c1be690e7fea3fefec2cf0ba78fef3805b15bd Mon Sep 17 00:00:00 2001 From: Thomas Druez Date: Fri, 12 Feb 2021 20:31:25 +0400 Subject: [PATCH] Update the documentation according to the changes #84 Signed-off-by: Thomas Druez --- docs/docker-image.rst | 2 +- docs/scanpipe-command-line.rst | 10 +++------- docs/scanpipe-concepts.rst | 7 ++----- docs/scanpipe-tutorial-1.rst | 10 +++++----- docs/scanpipe-tutorial-2.rst | 2 +- 5 files changed, 12 insertions(+), 19 deletions(-) diff --git a/docs/docker-image.rst b/docs/docker-image.rst index c724314d4..2a2fa3902 100644 --- a/docs/docker-image.rst +++ b/docs/docker-image.rst @@ -19,7 +19,7 @@ required for the creation of the Docker image. Clone the git `ScanCode.io repo `_, create an environment file, and build the Docker image:: - git clone git@github.com:nexB/scancode.io.git && cd scancode.io + git clone https://github.com/nexB/scancode.io.git && cd scancode.io make envfile docker-compose build diff --git a/docs/scanpipe-command-line.rst b/docs/scanpipe-command-line.rst index bffba5f0d..7df8d5ef3 100644 --- a/docs/scanpipe-command-line.rst +++ b/docs/scanpipe-command-line.rst @@ -76,7 +76,7 @@ copy ``~/docker/alpine-base.tar`` to the foo project :guilabel:`input/` director `$ scanpipe add-pipeline --project PROJECT ` ---------------------------------------------------------- -Add the ```` found at this location to the project named ``PROJECT``. +Add the ```` to the provided ``PROJECT``. You can use more than one ```` to add multiple pipelines at once. .. warning:: @@ -85,17 +85,13 @@ You can use more than one ```` to add multiple pipelines at once. For example, assuming you have created beforehand a project named "foo", this will add the docker pipeline to your project:: - $ scanpipe add-pipeline --project foo scanpipe/pipelines/docker.py + $ scanpipe add-pipeline --project foo docker `$ scanpipe run --project PROJECT` ---------------------------------- -Run all the pipelines of the project named ``PROJECT``. - -Optional arguments: - -- ``--resume`` Resume the latest failed pipeline execution. +Run the next pipeline of the project named ``PROJECT`` queue. `$ scanpipe show-pipeline --project PROJECT` diff --git a/docs/scanpipe-concepts.rst b/docs/scanpipe-concepts.rst index 7e70eeb0f..b79b32f23 100644 --- a/docs/scanpipe-concepts.rst +++ b/docs/scanpipe-concepts.rst @@ -46,14 +46,11 @@ Analysis results and reports are eventually posted at the end of a pipeline run. All pipelines are located in the ``scanpipe.pipelines`` module. Each pipeline consist of a Python script including one subclass of the ``Pipeline`` class. -Each step is a method of the ``Pipeline`` class decorated with a ``@step`` decorator. -At its end, a step states which is the next step to execute. +Each step is a method of the ``Pipeline`` class. +The execution order of the steps is declared through the ``steps`` class attribute. .. note:: One or more pipelines can be assigned to a project as a sequence. - If one pipeline of a sequence completes successfully, the next pipeline in - the queue for this project is launched automatically and this until all - the scheduled pipelines have executed. Codebase Resources diff --git a/docs/scanpipe-tutorial-1.rst b/docs/scanpipe-tutorial-1.rst index 7bc3c678d..3839229bd 100644 --- a/docs/scanpipe-tutorial-1.rst +++ b/docs/scanpipe-tutorial-1.rst @@ -39,7 +39,7 @@ Step-by-step - Add the docker pipeline to your project:: - $ scanpipe add-pipeline --project staticbox scanpipe/pipelines/docker.py + $ scanpipe add-pipeline --project docker - Check that the docker pipeline was added to your project:: @@ -59,13 +59,13 @@ Step-by-step pipeline run:: $ scanpipe show-pipeline --project staticbox - "[SUCCESS] scanpipe/pipelines/docker.py" + "[SUCCESS] docker" - Get the results of the pipeline run as a JSON file using the ``output`` command:: - $ scanpipe output --project staticbox results.json + $ scanpipe output --project staticbox --format json -- Open the ``results.json`` in your preferred viewer. +- Open the ``output/results-.json`` in your preferred viewer. ---- @@ -80,5 +80,5 @@ Step-by-step $ scanpipe create-project staticbox2 \ --input ~/30-alpine-nickolashkraus-staticbox-latest.tar \ - --pipeline scanpipe/pipelines/docker.py \ + --pipeline docker \ --run diff --git a/docs/scanpipe-tutorial-2.rst b/docs/scanpipe-tutorial-2.rst index 9d268587b..a67f80fc4 100644 --- a/docs/scanpipe-tutorial-2.rst +++ b/docs/scanpipe-tutorial-2.rst @@ -30,7 +30,7 @@ Step-by-step $ scanpipe create-project asgiref \ --input ~/asgiref-3.3.0-py3-none-any.whl \ - --pipeline scanpipe/pipelines/scan_codebase.py \ + --pipeline scan_codebase \ --run .. note::