Skip to content

Commit

Permalink
Docs: improve explanation of command parameters
Browse files Browse the repository at this point in the history
  • Loading branch information
mabar committed Mar 11, 2024
1 parent fdc5636 commit 7b83d67
Showing 1 changed file with 19 additions and 8 deletions.
27 changes: 19 additions & 8 deletions docs/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -601,7 +601,9 @@ Run scheduler once, executing jobs scheduled for the current minute

`bin/console scheduler:run`

- use `--json` to output json with job info and result
Options:

- `--json` - output json with job info and result

You can also change crontab settings to use command instead:

Expand All @@ -615,21 +617,30 @@ Run single job, ignoring scheduled time

`bin/console scheduler:run-job <id>`

- use `--no-force` to respect due time and only run job if it is due
- use `--json` to output json with job info and result
Options:

- `--no-force` - respect due time and only run job if it is due
- `--json` - output json with job info and result

### List command

List all scheduled jobs (in `expression / second (timezone) [id] name... next-due` format)

`bin/console scheduler:list`
```shell
bin/console scheduler:list
bin/console scheduler:list --next=3
bin/console scheduler:list --timezone=Europe/Prague
bin/console scheduler:list --explain
```

Options:

- use `--next` to sort jobs by their next execution time
- `--next` - sort jobs by their next execution time
- `--next=N` lists only *N* next jobs (e.g. `--next=3` prints maximally 3)
- use `-v` to display absolute times
- use `--timezone` (or `-tz`) to display times in specified timezone instead of one used by application
- `-v` - display absolute times
- `--timezone` (or `-tz`) - display times in specified timezone instead of one used by application
- e.g. `--tz=UTC`
- use `--explain` to explain whole expression, including [seconds](#seconds) and [timezones](#timezones)
- `--explain` - explain whole expression, including [seconds](#seconds) and [timezones](#timezones)
- [Explain command](#explain-command) with `--id` parameter can be used to explain specific job

### Worker command
Expand Down

0 comments on commit 7b83d67

Please sign in to comment.