Skip to content

Commit 72a4711

Browse files
authored
docs: add links with anchors (#440)
1 parent 81b4bda commit 72a4711

3 files changed

Lines changed: 21 additions & 9 deletions

File tree

README.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -20,11 +20,11 @@
2020

2121
This monorepo contains code for open-source Code PushUp NPM packages:
2222

23-
- [🧩 @code-pushup/cli](./packages/cli) - **CLI** for **collecting** audit results and **uploading** report to portal
24-
- [🧩 @code-pushup/core](./packages/core) - implementation of **core business logic** (useful for custom integrations)
25-
- [🧩 @code-pushup/models](./packages/models/) - **schemas and types** for data models (useful for custom plugins or other integrations)
26-
- [🧩 @code-pushup/utils](./packages/utils/) - various **utilities** (useful for custom plugins or other integrations)
23+
- [🧩 @code-pushup/cli](./packages/cli#readme) - **CLI** for **collecting** audit results and **uploading** report to portal
24+
- [🧩 @code-pushup/core](./packages/core#readme) - implementation of **core business logic** (useful for custom integrations)
25+
- [🧩 @code-pushup/models](./packages/models#readme) - **schemas and types** for data models (useful for custom plugins or other integrations)
26+
- [🧩 @code-pushup/utils](./packages/utils#readme) - various **utilities** (useful for custom plugins or other integrations)
2727
- plugins:
28-
- [📦 @code-pushup/eslint-plugin](./packages/plugin-eslint/) - static analysis using **ESLint** rules
28+
- [📦 @code-pushup/eslint-plugin](./packages/plugin-eslint#readme) - static analysis using **ESLint** rules
2929

3030
If you want to contribute, please refer to [CONTRIBUTING.md](./CONTRIBUTING.md).

packages/cli/README.md

Lines changed: 16 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,8 @@ _If you're looking for programmatic usage, then refer to the underlying [@code-p
2323
## Getting started
2424

2525
1. Install as a dev dependency with your package manager:
26+
<details>
27+
<summary>Installation command for <code>npm</code>, <code>yarn</code> and <code>pnpm</code></summary>
2628

2729
```sh
2830
npm install --save-dev @code-pushup/cli
@@ -36,6 +38,8 @@ _If you're looking for programmatic usage, then refer to the underlying [@code-p
3638
pnpm add --save-dev @code-pushup/cli
3739
```
3840

41+
</details>
42+
3943
2. Create a `code-pushup.config.js` configuration file (`.ts` or `.mjs` extensions are also supported).
4044

4145
```js
@@ -64,7 +68,13 @@ _If you're looking for programmatic usage, then refer to the underlying [@code-p
6468
};
6569
```
6670

67-
4. Optionally define your custom categories. This section provides an overview of thematically related audits and groups.
71+
4. Run the CLI with `npx code-pushup` (see `--help` for list of commands and arguments).
72+
73+
5. View report file(s) in output directory (specified by `persist.outputDir` configuration).
74+
75+
### Set up categories (optional)
76+
77+
1. Define your custom categories.
6878

6979
```js
7080
export default {
@@ -89,9 +99,9 @@ _If you're looking for programmatic usage, then refer to the underlying [@code-p
8999
};
90100
```
91101

92-
5. Run the CLI with `npx code-pushup` (see `--help` for list of commands and arguments).
102+
2. Run the CLI with `npx code-pushup`.
93103

94-
6. View report file(s) in output directory (specified by `persist.outputDir` configuration).
104+
3. View report file(s) including category section in output directory.
95105

96106
## Portal integration
97107

@@ -170,13 +180,15 @@ Each example is fully tested to demonstrate best practices for plugin testing as
170180
> All common options, except `--onlyPlugins`, can be specified in the configuration file as well.
171181
> CLI arguments take precedence over configuration file options.
172182

173-
> [!NOTE]
183+
> [!NOTE]
174184
> The `--upload.*` group of options is applicable to all commands except `collect`.
175185

176186
### Commands
177187

178188
#### `collect` command
179189

190+
<img src="./docs/images/cli-run-stdout-example.png" width="400" alt="example of code-pushup terminal output">
191+
180192
Usage:
181193
`code-pushup collect [options]`
182194

165 KB
Loading

0 commit comments

Comments
 (0)