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
The PDF files containing the downloaded Logilica reports are stored in a
52
52
temporary directory which is created if it does not exist; if it was created by
53
-
the tool, the directory is deleted after execution is complete. By default,
54
-
the directory is named `lwr_downloaded_pdfs`, and it is created in the current
55
-
directory, but an alternate path can be specified on the command line.
53
+
the tool, the directory is deleted after execution is complete.
56
54
57
55
Help is available on the command line:
56
+
58
57
```text
59
58
Usage: logilica-cli [OPTIONS] COMMAND [ARGS]...
60
59
@@ -80,6 +79,7 @@ Commands:
80
79
```
81
80
82
81
```text
82
+
logilica-cli weekly-report --help
83
83
Usage: logilica-cli weekly-report [OPTIONS]
84
84
85
85
Downloads and processes weekly report for teams specified in the
@@ -90,9 +90,11 @@ Options:
90
90
Name [env var: LOGILICA_DOMAIN; required]
91
91
-t, --downloads-temp-dir DIRECTORY
92
92
Path to a directory to receive downloaded
93
-
files (will be created if it doesn't exist;
94
-
will be deleted if created) [default:
95
-
./lwr_downloaded_pdfs]
93
+
files (if unspecified, a temporary directory
94
+
will be used; otherwise, the specified
95
+
directory will be created if it doesn't
96
+
exist; if the directory is created by the
97
+
tool, it will be deleted after the run)
96
98
-I, --input [logilica|local] Input source -- download from Logilica or
97
99
use pre-downloaded files [default:
98
100
logilica]
@@ -161,7 +163,35 @@ Options:
161
163
var: LOGILICA_EMAIL]
162
164
--help Show this message and exit.
163
165
```
166
+
164
167
Some dashboards can be quite slow to load into the UI, so, if you are running
165
168
the tool interactively and wish to track its progress, add a `-v` to the command
166
-
line to see informational messages. (If you are debugging or just nosy, adding
169
+
line to see informational messages. (If you are debugging or just nosy, adding
167
170
a _second_`-v` will add debugging messages to the output.)
171
+
172
+
## Development
173
+
174
+
If you are doing development on the tool, you may want to specify `-e` in the `pip install` command to install it in editable mode.
175
+
This means that you can make changes to the package's source code and those changes will be reflected in your project without having to reinstall the package.
176
+
177
+
For details on debugging the web interactions, see the `--pwdebug` option in the command help and the [Playwright documentation](https://playwright.dev/python/docs/running-tests).
178
+
179
+
### Linting and formatting rules
180
+
181
+
This project uses `pre-commit` to handle linting and formatting. The `pre-commit` tool reads its configuration from [`.pre-commit-config.yaml`](./.pre-commit-config.yaml)` and the configuration options for the individual linters and formatters can be found in the [`pyproject.toml`](./pyproject.toml) file.
182
+
The same configuration is used in CI.
183
+
184
+
To install and execute it locally, follow these steps:
185
+
186
+
```
187
+
pip install pre-commit
188
+
pre-commit install
189
+
pre-commit run --all-files --hook-stage [pre-commit|manual]
190
+
```
191
+
192
+
If you run `pre-commit` stage, you can check your files, if you run `manual` stage, it will modify your files to correct problems it finds.
193
+
194
+
### Enabling Red Hat InfoSec plugin
195
+
196
+
If you are developing locally within Red Hat, you should enable Red Hat InfoSec plugin. You can do that by uncommenting appropriate lines in `.pre-commit-config.yaml` file.
197
+
Make sure that you don't commit that change back upstream, as it would break the CI.
0 commit comments