You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
*`--divbase-url TEXT`: DivBase server URL to connect to. [default: http://localhost:8000/api]
45
-
*`-c, --config PATH`: Path to your user configuration file. If you didn't specify a custom path when you created it, you don't need to set this. [default: /home/roryc/.config/divbase/config.yaml]
46
45
*`-f, --force`: Force login again even if already logged in
*`-c, --config PATH`: Path to your user configuration file. If you didn't specify a custom path when you created it, you don't need to set this. [default: /home/roryc/.config/divbase/config.yaml]
*`create`: Create a user configuration file for...
20
19
*`add`: Add a new project to your user...
21
-
*`remove`: Remove a project from your user...
20
+
*`rm`: Remove a project from your user...
22
21
*`set-default`: Set your default project to use in all...
23
22
*`show-default`: Print the currently set default project to...
24
23
*`set-dload-dir`: Set the default download dir
25
24
*`show`: Pretty print the contents of your current...
26
25
27
-
## `divbase-cli config create`
28
-
29
-
Create a user configuration file for divbase-cli.
30
-
31
-
**Usage**:
32
-
33
-
```console
34
-
$ divbase-cli config create [OPTIONS]
35
-
```
36
-
37
-
**Options**:
38
-
39
-
*`-c, --config PATH`: Where to store your config file locally on your pc. [default: /home/roryc/.config/divbase/config.yaml]
40
-
*`--help`: Show this message and exit.
41
-
42
26
## `divbase-cli config add`
43
27
44
28
Add a new project to your user configuration file.
@@ -57,17 +41,16 @@ $ divbase-cli config add [OPTIONS] NAME
57
41
58
42
*`-u, --divbase-url TEXT`: DivBase API URL associated with this project. [default: http://localhost:8000/api]
59
43
*`-d, --default`: Set this project as the default project in your config file.
60
-
*`-c, --config PATH`: Path to your user configuration file. If you didn't specify a custom path when you created it, you don't need to set this. [default: /home/roryc/.config/divbase/config.yaml]
61
44
*`--help`: Show this message and exit.
62
45
63
-
## `divbase-cli config remove`
46
+
## `divbase-cli config rm`
64
47
65
48
Remove a project from your user configuration file.
66
49
67
50
**Usage**:
68
51
69
52
```console
70
-
$ divbase-cli config remove [OPTIONS] NAME
53
+
$ divbase-cli config rm [OPTIONS] NAME
71
54
```
72
55
73
56
**Arguments**:
@@ -76,7 +59,6 @@ $ divbase-cli config remove [OPTIONS] NAME
76
59
77
60
**Options**:
78
61
79
-
*`-c, --config PATH`: Path to your user configuration file. If you didn't specify a custom path when you created it, you don't need to set this. [default: /home/roryc/.config/divbase/config.yaml]
80
62
*`--help`: Show this message and exit.
81
63
82
64
## `divbase-cli config set-default`
@@ -95,7 +77,6 @@ $ divbase-cli config set-default [OPTIONS] NAME
95
77
96
78
**Options**:
97
79
98
-
*`-c, --config PATH`: Path to your user configuration file. If you didn't specify a custom path when you created it, you don't need to set this. [default: /home/roryc/.config/divbase/config.yaml]
*`-c, --config PATH`: Path to your user configuration file. If you didn't specify a custom path when you created it, you don't need to set this. [default: /home/roryc/.config/divbase/config.yaml]
*`-c, --config PATH`: Path to your user configuration file. If you didn't specify a custom path when you created it, you don't need to set this. [default: /home/roryc/.config/divbase/config.yaml]
136
115
*`--help`: Show this message and exit.
137
116
138
117
## `divbase-cli config show`
@@ -147,5 +126,4 @@ $ divbase-cli config show [OPTIONS]
147
126
148
127
**Options**:
149
128
150
-
*`-c, --config PATH`: Path to your user configuration file. If you didn't specify a custom path when you created it, you don't need to set this. [default: /home/roryc/.config/divbase/config.yaml]
*`--project TEXT`: Name of the DivBase project, if not provided uses the default in your DivBase config file
35
-
*`-c, --config PATH`: Path to your user configuration file. If you didn't specify a custom path when you created it, you don't need to set this. [default: /home/roryc/.config/divbase/config.yaml]
36
35
*`--help`: Show this message and exit.
37
36
38
37
## `divbase-cli dimensions show`
@@ -51,5 +50,4 @@ $ divbase-cli dimensions show [OPTIONS]
51
50
*`--filename TEXT`: If set, will show only the entry for this VCF filename.
52
51
*`--unique-scaffolds`: If set, will show all unique scaffold names found across all the VCF files in the project.
53
52
*`--project TEXT`: Name of the DivBase project, if not provided uses the default in your DivBase config file
54
-
*`-c, --config PATH`: Path to your user configuration file. If you didn't specify a custom path when you created it, you don't need to set this. [default: /home/roryc/.config/divbase/config.yaml]
Copy file name to clipboardExpand all lines: docs/cli/_auto_generated/files.md
-7Lines changed: 0 additions & 7 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -44,7 +44,6 @@ $ divbase-cli files ls [OPTIONS]
44
44
*`-p, --prefix TEXT`: Optional prefix to filter the listed files by name (only list files starting with this prefix).
45
45
*`-r, --include-results-files`: If set, will also show DivBase query results files which are hidden by default.
46
46
*`--project TEXT`: Name of the DivBase project, if not provided uses the default in your DivBase config file
47
-
*`-c, --config PATH`: Path to your user configuration file. If you didn't specify a custom path when you created it, you don't need to set this. [default: /home/roryc/.config/divbase/config.yaml]
48
47
*`--help`: Show this message and exit.
49
48
50
49
## `divbase-cli files info`
@@ -67,7 +66,6 @@ $ divbase-cli files info [OPTIONS] FILE_NAME
67
66
68
67
*`--tsv`: If set, will print the output in .TSV format for easier programmatic parsing.
69
68
*`--project TEXT`: Name of the DivBase project, if not provided uses the default in your DivBase config file
70
-
*`-c, --config PATH`: Path to your user configuration file. If you didn't specify a custom path when you created it, you don't need to set this. [default: /home/roryc/.config/divbase/config.yaml]
71
69
*`--help`: Show this message and exit.
72
70
73
71
## `divbase-cli files download`
@@ -105,7 +103,6 @@ You can also specify "." to download to the current directory.
105
103
*`--disable-verify-checksums`: Turn off checksum verification which is on by default. Checksum verification means all downloaded files are verified against their MD5 checksums.It is recommended to leave checksum verification enabled unless you have a specific reason to disable it.
106
104
*`--project-version TEXT`: User defined version of the project's at which to download the files. If not provided, downloads the latest version of all selected files.
107
105
*`--project TEXT`: Name of the DivBase project, if not provided uses the default in your DivBase config file
108
-
*`-c, --config PATH`: Path to your user configuration file. If you didn't specify a custom path when you created it, you don't need to set this. [default: /home/roryc/.config/divbase/config.yaml]
*`--version-id TEXT`: Specify this if you want to look at an older/specific version of the file. If not provided, the latest version of the file is used. To get a file's version ids, use the 'divbase-cli file info [FILE_NAME]' command.
135
132
*`--project TEXT`: Name of the DivBase project, if not provided uses the default in your DivBase config file
136
-
*`-c, --config PATH`: Path to your user configuration file. If you didn't specify a custom path when you created it, you don't need to set this. [default: /home/roryc/.config/divbase/config.yaml]
*`--file-list PATH`: Text file with list of files to upload.
162
158
*`--disable-safe-mode`: Turn off safe mode which is on by default. Safe mode adds 2 extra bits of security by first calculating the MD5 checksum of each file that you're about to upload:(1) Checks if any of the files you're about to upload already exist (by comparing name and checksum) and if so stops the upload process.(2) Sends the file's checksum when the file is uploaded so the server can verify the upload was successful (by calculating and comparing the checksums).It is recommended to leave safe mode enabled unless you have a specific reason to disable it.
163
159
*`--project TEXT`: Name of the DivBase project, if not provided uses the default in your DivBase config file
164
-
*`-c, --config PATH`: Path to your user configuration file. If you didn't specify a custom path when you created it, you don't need to set this. [default: /home/roryc/.config/divbase/config.yaml]
*`--file-list PATH`: Text file with list of files to delete.
190
185
*`--dry-run`: If set, will not actually delete the files, just print what would be deleted.
191
186
*`--project TEXT`: Name of the DivBase project, if not provided uses the default in your DivBase config file
192
-
*`-c, --config PATH`: Path to your user configuration file. If you didn't specify a custom path when you created it, you don't need to set this. [default: /home/roryc/.config/divbase/config.yaml]
*`--file-list PATH`: Text file with list of files to restore.
218
212
*`--project TEXT`: Name of the DivBase project, if not provided uses the default in your DivBase config file
219
-
*`-c, --config PATH`: Path to your user configuration file. If you didn't specify a custom path when you created it, you don't need to set this. [default: /home/roryc/.config/divbase/config.yaml]
*`--show-sample-results / --no-show-sample-results`: Print sample_ID and Filename results from the query. [default: no-show-sample-results]
50
50
*`--metadata-tsv-name TEXT`: Name of the sample metadata TSV file in the project's data store on DivBase. [default: sample_metadata.tsv]
51
51
*`--project TEXT`: Name of the DivBase project, if not provided uses the default in your DivBase config file
52
-
*`-c, --config PATH`: Path to your user configuration file. If you didn't specify a custom path when you created it, you don't need to set this. [default: /home/roryc/.config/divbase/config.yaml]
53
52
*`--help`: Show this message and exit.
54
53
55
54
## `divbase-cli query bcftools-pipe`
@@ -81,5 +80,4 @@ will be performed. E.g. 'Area:West of Ireland,Northern Portugal;Sex:F'
81
80
*`--command TEXT`: String consisting of the bcftools command to run on the files returned by the tsv query. [required]
82
81
*`--metadata-tsv-name TEXT`: Name of the sample metadata TSV file in the project's data store on DivBase. [default: sample_metadata.tsv]
83
82
*`--project TEXT`: Name of the DivBase project, if not provided uses the default in your DivBase config file
84
-
*`-c, --config PATH`: Path to your user configuration file. If you didn't specify a custom path when you created it, you don't need to set this. [default: /home/roryc/.config/divbase/config.yaml]
Copy file name to clipboardExpand all lines: docs/cli/_auto_generated/task-history.md
-3Lines changed: 0 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -32,7 +32,6 @@ $ divbase-cli task-history user [OPTIONS]
32
32
33
33
**Options**:
34
34
35
-
*`-c, --config PATH`: Path to your user configuration file. If you didn't specify a custom path when you created it, you don't need to set this. [default: /home/roryc/.config/divbase/config.yaml]
36
35
*`--limit INTEGER`: Maximum number of tasks to display in the terminal. Sorted by recency. [default: 10]
37
36
*`--project TEXT`: Optional project name to filter the user's task history by project.
38
37
*`--help`: Show this message and exit.
@@ -53,7 +52,6 @@ $ divbase-cli task-history id [OPTIONS] TASK_ID
53
52
54
53
**Options**:
55
54
56
-
*`-c, --config PATH`: Path to your user configuration file. If you didn't specify a custom path when you created it, you don't need to set this. [default: /home/roryc/.config/divbase/config.yaml]
*`-c, --config PATH`: Path to your user configuration file. If you didn't specify a custom path when you created it, you don't need to set this. [default: /home/roryc/.config/divbase/config.yaml]
76
73
*`--limit INTEGER`: Maximum number of tasks to display in the terminal. Sorted by recency. [default: 10]
Copy file name to clipboardExpand all lines: docs/cli/_auto_generated/version.md
+1-4Lines changed: 1 addition & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -39,7 +39,6 @@ $ divbase-cli version add [OPTIONS] NAME
39
39
40
40
*`--description TEXT`: Optional description of the version.
41
41
*`--project TEXT`: Name of the DivBase project, if not provided uses the default in your DivBase config file
42
-
*`-c, --config PATH`: Path to your user configuration file. If you didn't specify a custom path when you created it, you don't need to set this. [default: /home/roryc/.config/divbase/config.yaml]
43
42
*`--help`: Show this message and exit.
44
43
45
44
## `divbase-cli version list`
@@ -59,8 +58,8 @@ $ divbase-cli version list [OPTIONS]
59
58
**Options**:
60
59
61
60
*`--project TEXT`: Name of the DivBase project, if not provided uses the default in your DivBase config file
62
-
*`-c, --config PATH`: Path to your user configuration file. If you didn't specify a custom path when you created it, you don't need to set this. [default: /home/roryc/.config/divbase/config.yaml]
63
61
*`--include-deleted / --no-include-deleted`: Include soft-deleted versions in the listing. [default: no-include-deleted]
62
+
*`--tsv`: If set, will print the output in .TSV format for easier programmatic parsing.
64
63
*`--help`: Show this message and exit.
65
64
66
65
## `divbase-cli version info`
@@ -80,7 +79,6 @@ $ divbase-cli version info [OPTIONS] VERSION
80
79
**Options**:
81
80
82
81
*`--project TEXT`: Name of the DivBase project, if not provided uses the default in your DivBase config file
83
-
*`-c, --config PATH`: Path to your user configuration file. If you didn't specify a custom path when you created it, you don't need to set this. [default: /home/roryc/.config/divbase/config.yaml]
84
82
*`--help`: Show this message and exit.
85
83
86
84
## `divbase-cli version delete`
@@ -102,5 +100,4 @@ $ divbase-cli version delete [OPTIONS] NAME
102
100
**Options**:
103
101
104
102
*`--project TEXT`: Name of the DivBase project, if not provided uses the default in your DivBase config file
105
-
*`-c, --config PATH`: Path to your user configuration file. If you didn't specify a custom path when you created it, you don't need to set this. [default: /home/roryc/.config/divbase/config.yaml]
Copy file name to clipboardExpand all lines: docs/development/celery_task_implementation.md
+1-2Lines changed: 1 addition & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -258,7 +258,7 @@ The DivBase client uses the [Typer](https://typer.tiangolo.com/) library to buil
258
258
- There needs to be a Typer app (on the form `query_app = typer.Typer()`) to which the CLI command functions needs to be connected. The app needs to be initiated with `app.add_typer(query_app, name="query")` in `./packages/divbase-cli/src/divbase_cli/divbase_cli.py`.
259
259
- The typer app name is used as a decorator for the function, e.g. `@query_app.command("bcftools-pipe")`. The argument of the decorator will become the command for the CLI.
260
260
- Pack the task arguments in the Pydantic request model (see Section 2.2), e.g. `request_data=BcftoolsQueryRequest()` for type validation.
261
-
- The `resolve_project()` helper function is be used to fetch the data from the users local config and is needed for the established pattern to make the request. This helper function need that the CLI function args contain `project: str | None = PROJECT_NAME_OPTION,` and `config_file: Path = CONFIG_FILE_OPTION,`. See an existing CLI file for more details on the constants they are calling.
261
+
- The `resolve_project()` helper function is be used to fetch the data from the users local config and is needed for the established pattern to make the request. This helper function need that the CLI function args contain `project: str | None = PROJECT_NAME_OPTION,`. See an existing CLI file for more details on the constants they are calling.
262
262
- The main function call for all DivBase CLI->API interactions is `make_authenticated_request()`. If the user is logged in to the CLI, it sends the user's JSON Web Token as part of the request, which the API uses to validate the user's identity and project role/permissions.
263
263
- The arguments `method="POST",divbase_base_url=project_config.divbase_url` should always be included as is.
264
264
-`api_route` is the route URL defined in the corresponding endpoint (see Section 2.3).
@@ -281,7 +281,6 @@ def pipe_query(
281
281
command: str=BCFTOOLS_ARGUMENT,
282
282
metadata_tsv_name: str=METADATA_TSV_ARGUMENT,
283
283
project: str|None=PROJECT_NAME_OPTION,
284
-
config_file: Path =CONFIG_FILE_OPTION,
285
284
) -> None:
286
285
"""
287
286
Submit a query to run on the DivBase API. A single, merged VCF file will be added to the project's storage bucket on success.
Copy file name to clipboardExpand all lines: docs/user-guides/quick-start.md
+1-9Lines changed: 1 addition & 9 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -37,15 +37,7 @@ pipx install divbase-cli
37
37
38
38
If you do not have `pipx` installed, you can install it by following [the official instructions from pipx](https://pipx.pypa.io/stable/installation/). Refer to the [Installation Guide](installation.md) for more detailed instructions or other ways to install divbase-cli.
39
39
40
-
## Step 4: Configure the CLI
41
-
42
-
Set up your user configuration file:
43
-
44
-
```bash
45
-
divbase-cli config create
46
-
```
47
-
48
-
This creates a configuration file stored on your local device at: `~/.config/divbase/config.yaml`.
40
+
## Step 4: Add your project(s) to your divbase-cli config
0 commit comments