From 8b945eb601ab05f74b5c4fab05de058c0144efc9 Mon Sep 17 00:00:00 2001 From: Daan Rosendal Date: Sat, 4 Nov 2023 14:55:21 +0100 Subject: [PATCH 1/4] docs(reana-client-cli-api): add share-add command docs (#190) Adds a new command to the CLI to share a workflow with a user. Closes reanahub/reana-client#680 --- AUTHORS.md | 1 + docs/reference/reana-client-cli-api/index.md | 20 ++++++++++++++++++++ 2 files changed, 21 insertions(+) diff --git a/AUTHORS.md b/AUTHORS.md index 9347a6b..9d6fdb0 100644 --- a/AUTHORS.md +++ b/AUTHORS.md @@ -6,6 +6,7 @@ The list of contributors in alphabetical order: - [Agisilaos Kounelis](https://orcid.org/0000-0001-9312-3189) - [Audrius Mecionis](https://orcid.org/0000-0002-3759-1663) - [Clemens Lange](https://orcid.org/0000-0002-3632-3157) +- [Daan Rosendal](https://orcid.org/0000-0002-3447-9000) - [Diego Rodriguez](https://orcid.org/0000-0003-0649-2002) - [Domenic Gosein](https://orcid.org/0000-0002-1546-0435) - [Elena Gazzarrini](https://orcid.org/0000-0001-5772-5166) diff --git a/docs/reference/reana-client-cli-api/index.md b/docs/reference/reana-client-cli-api/index.md index f80cba9..73b184e 100644 --- a/docs/reference/reana-client-cli-api/index.md +++ b/docs/reference/reana-client-cli-api/index.md @@ -37,6 +37,9 @@ Workflow execution commands: stop Stop a running workflow. validate Validate workflow specification file. +Workflow sharing commands: + share-add Share a workflow with other users (read-only). + Workspace interactive commands: close Close an interactive session. open Open an interactive session inside the workspace. @@ -286,6 +289,23 @@ Examples: $ reana-client run -w myanalysis-test-big -p myparam=mybigvalue +## Workflow sharing commands + +### share-add + +Share a workflow with other users (read-only). + +The `share-add` command allows sharing a workflow with other users. The +users will be able to view the workflow but not modify it. + +Examples: + + +$ reana-client share-add -w myanalysis.42 --user bob@cern.ch + + +$ reana-client share-add -w myanalysis.42 --user bob@cern.ch --user cecile@cern.ch --message "Please review my analysis" --valid-until 2024-12-31 + ## Workspace interactive commands ### open From 70f49d70bd88b8113f57ad5b2e2562521224fc80 Mon Sep 17 00:00:00 2001 From: Daan Rosendal Date: Wed, 8 Nov 2023 23:37:26 +0100 Subject: [PATCH 2/4] docs(reana-client-cli-api): add share-remove command docs (#190) Adds a new command to the docs for unsharing a workflow. Closes reanahub/reana-client#681 --- docs/reference/reana-client-cli-api/index.md | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/docs/reference/reana-client-cli-api/index.md b/docs/reference/reana-client-cli-api/index.md index 73b184e..8c8d10e 100644 --- a/docs/reference/reana-client-cli-api/index.md +++ b/docs/reference/reana-client-cli-api/index.md @@ -38,7 +38,8 @@ Workflow execution commands: validate Validate workflow specification file. Workflow sharing commands: - share-add Share a workflow with other users (read-only). + share-add Share a workflow with other users (read-only). + share-remove Unshare a workflow. Workspace interactive commands: close Close an interactive session. @@ -306,6 +307,18 @@ $ reana-client share-add -w myanalysis.42 --user bob@cern.ch $ reana-client share-add -w myanalysis.42 --user bob@cern.ch --user cecile@cern.ch --message "Please review my analysis" --valid-until 2024-12-31 +### share-remove + +Unshare a workflow. + +The `share-remove` command allows for unsharing a workflow. The workflow +will no longer be visible to the users with whom it was shared. + +Example: + + +$ reana-client share-remove -w myanalysis.42 --user bob@example.org + ## Workspace interactive commands ### open From ac427f977acb0cd0b4491145062e4fdf3e169359 Mon Sep 17 00:00:00 2001 From: Daan Rosendal Date: Tue, 14 Nov 2023 22:28:35 +0100 Subject: [PATCH 3/4] docs(reana-client-cli-api): add share-status command docs (#190) Adds a new command to the docs for retrieving whom a workflow is shared with. Closes reanahub/reana-client#686 --- docs/reference/reana-client-cli-api/index.md | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/docs/reference/reana-client-cli-api/index.md b/docs/reference/reana-client-cli-api/index.md index 8c8d10e..23ae76e 100644 --- a/docs/reference/reana-client-cli-api/index.md +++ b/docs/reference/reana-client-cli-api/index.md @@ -40,6 +40,7 @@ Workflow execution commands: Workflow sharing commands: share-add Share a workflow with other users (read-only). share-remove Unshare a workflow. + share-status Show with whom a workflow is shared. Workspace interactive commands: close Close an interactive session. @@ -319,6 +320,17 @@ Example: $ reana-client share-remove -w myanalysis.42 --user bob@example.org +### share-status + +Show with whom a workflow is shared. + +The `share-status` command allows for checking with whom a workflow is +shared. + +Example: + +$ reana-client share-status -w myanalysis.42 + ## Workspace interactive commands ### open From 3668003493eabe22b79172611ea0fe07fa3d3661 Mon Sep 17 00:00:00 2001 From: Daan Rosendal Date: Tue, 21 Nov 2023 18:02:58 +0100 Subject: [PATCH 4/4] docs(reana-client-cli-api): add list command sharing options (#190) Adds extra docs for `list` command to the docs for new sharing related arguments. Closes reanahub/reana-client#687 --- docs/reference/reana-client-cli-api/index.md | 33 ++++++++++++++------ 1 file changed, 24 insertions(+), 9 deletions(-) diff --git a/docs/reference/reana-client-cli-api/index.md b/docs/reference/reana-client-cli-api/index.md index 23ae76e..4b1c1d6 100644 --- a/docs/reference/reana-client-cli-api/index.md +++ b/docs/reference/reana-client-cli-api/index.md @@ -126,9 +126,21 @@ List all workflows and sessions. The ``list`` command lists workflows and sessions. By default, the list of workflows is returned. If you would like to see the list of your open interactive sessions, you need to pass the ``--sessions`` command-line -option. +option. If you would like to see the list of all workflows, including those +shared with you, you need to pass the ``--shared`` command-line option. -Example: +Along with specific user emails, you can pass the following special values +to the ``--shared-by`` and ``--shared-with`` command-line options: + + - ``--shared-by anybody``: list workflows shared with you by anybody. + + - ``--shared-with anybody``: list your shared workflows exclusively. + + - ``--shared-with nobody``: list your unshared workflows exclusively. + + - ``--shared-with bob@cern.ch``: list workflows shared with bob@cern.ch + +Examples: $ reana-client list --all @@ -136,6 +148,12 @@ Example: $ reana-client list --verbose --bytes + $ reana-client list --shared + + $ reana-client list --shared-by bob@cern.ch + + $ reana-client list --shared-with anybody + ### create Create a new workflow. @@ -302,11 +320,9 @@ users will be able to view the workflow but not modify it. Examples: - -$ reana-client share-add -w myanalysis.42 --user bob@cern.ch + $ reana-client share-add -w myanalysis.42 --user bob@example.org - -$ reana-client share-add -w myanalysis.42 --user bob@cern.ch --user cecile@cern.ch --message "Please review my analysis" --valid-until 2024-12-31 + $ reana-client share-add -w myanalysis.42 --user bob@example.org --user cecile@example.org --message "Please review my analysis" --valid-until 2025-12-31 ### share-remove @@ -317,8 +333,7 @@ will no longer be visible to the users with whom it was shared. Example: - -$ reana-client share-remove -w myanalysis.42 --user bob@example.org + $ reana-client share-remove -w myanalysis.42 --user bob@example.org ### share-status @@ -329,7 +344,7 @@ shared. Example: -$ reana-client share-status -w myanalysis.42 + $ reana-client share-status -w myanalysis.42 ## Workspace interactive commands