@keyline-icons/cli 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md ADDED
@@ -0,0 +1,56 @@
1
+ # @keyline-icons/cli
2
+
3
+ Search [Keyline Icons](https://keylineicons.com) and copy them into your project
4
+ from the terminal. No install, no dependencies, no network.
5
+
6
+ ```bash
7
+ npx @keyline-icons/cli search arrow
8
+ npx @keyline-icons/cli add circle-arrow-down bell --out src/icons
9
+ npx @keyline-icons/cli show check > check.svg
10
+ ```
11
+
12
+ ## Commands
13
+
14
+ | | |
15
+ | --- | --- |
16
+ | `search <query>` | Find icons by name, ranked |
17
+ | `show <name>` | Print one icon's SVG to stdout |
18
+ | `add <name...>` | Write icons into a directory |
19
+ | `list` | Print every icon name |
20
+
21
+ | Option | |
22
+ | --- | --- |
23
+ | `-s, --style <s>` | `stroke`, `duotone` or `fill`. Default `stroke`. |
24
+ | `-o, --out <dir>` | Where `add` writes. Default `./icons`. |
25
+ | `-l, --limit <n>` | Max results for `search`. Default 25. |
26
+
27
+ ## It pipes
28
+
29
+ `show` and `list` write only their payload to stdout. Counts, headings and
30
+ hints go to stderr, so redirecting gets you a file rather than a file with a
31
+ banner stuck to the top:
32
+
33
+ ```bash
34
+ keyline-icons show check > check.svg
35
+ keyline-icons list | grep chart
36
+ keyline-icons show mail --style fill | pbcopy
37
+ ```
38
+
39
+ Colour is switched off automatically when stdout is not a terminal.
40
+
41
+ ## Notes
42
+
43
+ **`add` resolves every name before writing any of them.** A typo in the third of
44
+ five leaves nothing on disk, rather than two files and an error.
45
+
46
+ **A missing style is explained, not silently skipped.** `bar-chart` has no fill,
47
+ because it is three open strokes with no interior to fill. Duotone and fill need
48
+ a fillable region, from the glyph's own enclosed area or from a square/circle
49
+ container.
50
+
51
+ **Typos resolve.** `chekc` suggests `check`; `arow` suggests the `arrow-*`
52
+ family, even though there is no bare `arrow` icon.
53
+
54
+ ## Licence
55
+
56
+ MIT.