Skip to content

Commit ef13e44

Browse files
committed
Update Readme with example output formats
1 parent 6ddb9b1 commit ef13e44

File tree

2 files changed

+29
-4
lines changed

2 files changed

+29
-4
lines changed

README.md

+28-3
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,32 @@ Output formatting works for both, the `list` and the `check` command.
8686
To get an overview of the different format options, try:
8787

8888
```bash
89-
conda-deny check --help
90-
# Or:
91-
conda-deny list --help
89+
$ conda-deny list --output csv
90+
package_name,version,license,platform,build,safe
91+
_openmp_mutex,4.5,BSD-3-Clause,linux-aarch64,2_gnu,false
92+
_openmp_mutex,4.5,BSD-3-Clause,linux-64,2_gnu,false
93+
...
94+
95+
$ conda-deny list --output json-pretty
96+
{
97+
"unsafe": [
98+
{
99+
"build": "conda_forge",
100+
"license": {
101+
"Invalid": "None"
102+
},
103+
"package_name": "_libgcc_mutex",
104+
"platform": "linux-64",
105+
"version": "0.1"
106+
},
107+
{
108+
"build": "h57d6b7b_14",
109+
"license": {
110+
"Invalid": "LGPL-2.0-or-later AND LGPL-2.0-or-later WITH exceptions AND GPL-2.0-or-later AND MPL-2.0"
111+
},
112+
"package_name": "_sysroot_linux-aarch64_curr_repodata_hack",
113+
"platform": "noarch",
114+
"version": "4"
115+
},
116+
...
92117
```

src/lib.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -216,7 +216,7 @@ pub fn get_config_options(
216216
toml_config.get_ignore_pypi()
217217
};
218218

219-
let output_format = cli_config.output_format().unwrap_or(OutputFormat::Default);
219+
let output_format = cli_config.output_format().unwrap_or_default();
220220

221221
let lockfile_or_prefix =
222222
get_lockfile_or_prefix(lockfile, prefix, platforms, environments, ignore_pypi)?;

0 commit comments

Comments
 (0)