Skip to content

Commit a170597

Browse files
authored
chore: Update schema.json (#159)
1 parent beb3c48 commit a170597

File tree

2 files changed

+336
-383
lines changed

2 files changed

+336
-383
lines changed

README.md

Lines changed: 122 additions & 122 deletions
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,8 @@ Automates terminal operations.
2929
- [`validate`](#clive-validate)
3030
- [`completion`](#clive-completion)
3131
- [Configuration](#gear-configuration)
32-
- [`actions`](#actions)
3332
- [`settings`](#settings)
33+
- [`actions`](#actions)
3434
- [Examples](#book-examples)
3535
- [License](#memo-license)
3636

@@ -173,127 +173,8 @@ Available shells:
173173

174174
The config file consists of `actions` and `settings`.
175175

176-
- [`actions`](#actions) - Actions to run.
177176
- [`settings`](#settings) - Basic settings (font size, default speed, etc.) .
178-
179-
### `actions`
180-
181-
Actions to run.
182-
Available actions:
183-
184-
- [`type`](#type) - Type characters.
185-
- [`key`](#key) - Enter special keys.
186-
- [`ctrl`](#ctrl) - Press the Ctrl key with other keys.
187-
- [`sleep`](#sleep) - Sleep for a specified number of milliseconds.
188-
- [`pause`](#pause) - Pause actions.
189-
- [`screenshot`](#screenshot) - Take a screenshot.
190-
191-
#### `type`
192-
193-
Type characters.
194-
195-
| Field | Required | Default | Description |
196-
| ------- | -------- | ------- | ------------------------------------------- |
197-
| `type` | **Yes** | N/A | Characters to type. |
198-
| `count` | No | `1` | Number of times to repeat the action. |
199-
| `speed` | No | `10` | Interval between key typing (milliseconds). |
200-
201-
```yaml
202-
# e.g.
203-
actions:
204-
- type: echo 'Hello World'
205-
count: 10 # Optional
206-
speed: 100 # Optional
207-
```
208-
209-
#### `key`
210-
211-
Enter special keys.
212-
Available keys:
213-
214-
- `esc`
215-
- `backspace`
216-
- `tab`
217-
- `enter`
218-
- `left`
219-
- `up`
220-
- `right`
221-
- `down`
222-
- `space`
223-
224-
| Field | Required | Default | Description |
225-
| ------- | -------- | ------- | ------------------------------------------- |
226-
| `key` | **Yes** | N/A | Special key to type. |
227-
| `count` | No | `1` | Number of times to repeat the action. |
228-
| `speed` | No | `10` | Interval between key typing (milliseconds). |
229-
230-
```yaml
231-
# e.g.
232-
actions:
233-
- key: enter
234-
count: 10 # Optional
235-
speed: 100 # Optional
236-
```
237-
238-
#### `ctrl`
239-
240-
Press the Ctrl key with other keys.
241-
242-
| Field | Required | Default | Description |
243-
| ------- | -------- | ------- | ------------------------------------------- |
244-
| `ctrl` | **Yes** | N/A | Characters to enter with the ctrl key. |
245-
| `count` | No | `1` | Number of times to repeat the action. |
246-
| `speed` | No | `10` | Interval between key typing (milliseconds). |
247-
248-
```yaml
249-
# e.g.
250-
actions:
251-
- ctrl: c # Ctrl+c
252-
count: 10 # Optional
253-
speed: 100 # Optional
254-
```
255-
256-
#### `sleep`
257-
258-
Sleep for a specified number of milliseconds.
259-
260-
| Field | Required | Default | Description |
261-
| ------- | -------- | ------- | ----------------------------- |
262-
| `sleep` | **Yes** | N/A | Time to sleep (milliseconds). |
263-
264-
```yaml
265-
# e.g.
266-
actions:
267-
- sleep: 3000 # Sleep for 3 seconds.
268-
```
269-
270-
#### `pause`
271-
272-
Pause actions.
273-
Press enter to continue.
274-
275-
```yaml
276-
# e.g.
277-
actions:
278-
- pause
279-
```
280-
281-
#### `screenshot`
282-
283-
Take a screenshot.
284-
Screenshots are saved in `screenshots/`.
285-
The directory to save the screenshots can be changed in [`settings.screenshotsDir`](#screenshotsdir).
286-
287-
| Field | Required | Default | Description |
288-
| ------------ | -------- | ------------------------------------- | ---------------------------- |
289-
| `screenshot` | No | `<ACTION_INDEX>_<yyyymmddHHMMSS>.png` | File name of the screenshot. |
290-
291-
```yaml
292-
# e.g.
293-
actions:
294-
- screenshot
295-
- screenshot: foobar.png # Optional
296-
```
177+
- [`actions`](#actions) - Actions to run.
297178

298179
### `settings`
299180

@@ -384,7 +265,7 @@ See the [go-rod documentation](https://github.com/go-rod/go-rod.github.io/blob/m
384265
```yaml
385266
# e.g.
386267
settings:
387-
browserBin: /Applications/Sidekick.app/Contents/MacOS/Sidekick # use Sidekick
268+
browserBin: /Applications/Vivaldi.app/Contents/MacOS/Vivaldi # use Vivaldi
388269
```
389270

390271
#### `headless`
@@ -418,6 +299,125 @@ settings:
418299
height: 800
419300
```
420301

302+
### `actions`
303+
304+
Actions to run.
305+
Available actions:
306+
307+
- [`type`](#type) - Type characters.
308+
- [`key`](#key) - Enter special keys.
309+
- [`ctrl`](#ctrl) - Press the Ctrl key with other keys.
310+
- [`sleep`](#sleep) - Sleep for a specified number of milliseconds.
311+
- [`pause`](#pause) - Pause actions.
312+
- [`screenshot`](#screenshot) - Take a screenshot.
313+
314+
#### `type`
315+
316+
Type characters.
317+
318+
| Field | Required | Default | Description |
319+
| ------- | -------- | ------- | ------------------------------------------- |
320+
| `type` | **Yes** | N/A | Characters to type. |
321+
| `count` | No | `1` | Number of times to repeat the action. |
322+
| `speed` | No | `10` | Interval between key typing (milliseconds). |
323+
324+
```yaml
325+
# e.g.
326+
actions:
327+
- type: echo 'Hello World'
328+
count: 10 # Optional
329+
speed: 100 # Optional
330+
```
331+
332+
#### `key`
333+
334+
Enter special keys.
335+
Available keys:
336+
337+
- `esc`
338+
- `backspace`
339+
- `tab`
340+
- `enter`
341+
- `left`
342+
- `up`
343+
- `right`
344+
- `down`
345+
- `space`
346+
347+
| Field | Required | Default | Description |
348+
| ------- | -------- | ------- | ------------------------------------------- |
349+
| `key` | **Yes** | N/A | Special key to type. |
350+
| `count` | No | `1` | Number of times to repeat the action. |
351+
| `speed` | No | `10` | Interval between key typing (milliseconds). |
352+
353+
```yaml
354+
# e.g.
355+
actions:
356+
- key: enter
357+
count: 10 # Optional
358+
speed: 100 # Optional
359+
```
360+
361+
#### `ctrl`
362+
363+
Press the Ctrl key with other keys.
364+
365+
| Field | Required | Default | Description |
366+
| ------- | -------- | ------- | ------------------------------------------- |
367+
| `ctrl` | **Yes** | N/A | Characters to enter with the ctrl key. |
368+
| `count` | No | `1` | Number of times to repeat the action. |
369+
| `speed` | No | `10` | Interval between key typing (milliseconds). |
370+
371+
```yaml
372+
# e.g.
373+
actions:
374+
- ctrl: c # Ctrl+c
375+
count: 10 # Optional
376+
speed: 100 # Optional
377+
```
378+
379+
#### `sleep`
380+
381+
Sleep for a specified number of milliseconds.
382+
383+
| Field | Required | Default | Description |
384+
| ------- | -------- | ------- | ----------------------------- |
385+
| `sleep` | **Yes** | N/A | Time to sleep (milliseconds). |
386+
387+
```yaml
388+
# e.g.
389+
actions:
390+
- sleep: 3000 # Sleep for 3 seconds.
391+
```
392+
393+
#### `pause`
394+
395+
Pause actions.
396+
Press enter to continue.
397+
398+
```yaml
399+
# e.g.
400+
actions:
401+
- pause
402+
```
403+
404+
#### `screenshot`
405+
406+
Take a screenshot.
407+
Screenshots are saved in `screenshots/`.
408+
The directory to save the screenshots can be changed in [`settings.screenshotsDir`](#screenshotsdir).
409+
410+
| Field | Required | Default | Description |
411+
| ------------ | -------- | ------------------------------------- | ---------------------------- |
412+
| `screenshot` | No | `<ACTION_INDEX>_<yyyymmddHHMMSS>.png` | File name of the screenshot. |
413+
414+
```yaml
415+
# e.g.
416+
actions:
417+
- screenshot
418+
- screenshot: foobar.png # Optional
419+
```
420+
421421
## :book: Examples
422422

423423
For more examples see the [`examples/`](./examples/) directory.

0 commit comments

Comments
 (0)