Update #4455, Regenerate all commands' docs (#4557)

This commit is contained in:
Justin Ma
2022-02-20 09:13:33 +08:00
committed by GitHub
parent aea4355d04
commit 2ecae0ef43
48 changed files with 481 additions and 52 deletions

View File

@ -4,29 +4,35 @@ layout: command
version: 0.59.0
---
Format a given date using the given format string.
Format a given date using a format string.
## Signature
```> date format (format string)```
```> date format (format string) --list```
## Parameters
- `format string`: the desired date format
- `--list`: lists strftime cheatsheet
## Examples
Format a given date using the given format string.
Format a given date using the default format (RFC 2822).
```shell
> "2021-10-22 20:00:12 +01:00" | date format
```
Format a given date using a given format string.
```shell
> date format '%Y-%m-%d'
```
Format a given date using the given format string.
Format a given date using a given format string.
```shell
> date format "%Y-%m-%d %H:%M:%S"
```
Format a given date using the given format string.
Format a given date using a given format string.
```shell
> "2021-10-22 20:00:12 +01:00" | date format "%Y-%m-%d"
```