aboutsummaryrefslogtreecommitdiffstats
path: root/docs/stats.md
diff options
context:
space:
mode:
authorBenjamin Vergnaud <9599845+bvergnaud@users.noreply.github.com>2022-10-21 21:21:14 +0200
committerGitHub <noreply@github.com>2022-10-21 20:21:14 +0100
commit8b9aae7076f39a1ebeecb3e2b823503f437812fa (patch)
tree713e9b55cc8a4fef65a576f6f3f1bf5a88c6e847 /docs/stats.md
parentBump clap from 4.0.15 to 4.0.18 (#578) (diff)
downloadatuin-8b9aae7076f39a1ebeecb3e2b823503f437812fa.zip
docs: add more details about date parsing in the stats command (#579)
* docs: add more details about date parsing in the stats command * chore: Replace chrono-english crate with interim
Diffstat (limited to '')
-rw-r--r--docs/stats.md22
1 files changed, 18 insertions, 4 deletions
diff --git a/docs/stats.md b/docs/stats.md
index 9c08ce19..b6834167 100644
--- a/docs/stats.md
+++ b/docs/stats.md
@@ -1,10 +1,18 @@
# `atuin stats`
Atuin can also calculate stats based on your history - this is currently a
-little basic, but more features to come
+little basic, but more features to come.
+
+## 1-day stats
+
+You provide the starting point, and Atuin computes the stats for 24h from that point.
+Date parsing is provided by `interim`, which supports different formats
+for full or relative dates. Certain formats rely on the dialect option in your
+[configuration](config.md#dialect) to differentiate day from month.
+Refer to [the module's documentation](https://docs.rs/interim/0.1.0/interim/#supported-formats) for more details on the supported date formats.
```
-$ atuin stats day last friday
+$ atuin stats last friday
+---------------------+------------+
| Statistic | Value |
@@ -16,12 +24,18 @@ $ atuin stats day last friday
| Unique commands ran | 213 |
+---------------------+------------+
-$ atuin stats day 01/01/21 # also accepts absolute dates
+# A few more examples:
+$ atuin stats 2018-04-01
+$ atuin stats April 1
+$ atuin stats 01/04/22
+$ atuin stats last thursday 3pm # between last thursday 3:00pm and the following friday 3:00pm
```
-It can also calculate statistics for all of known history:
+## Full history stats
```
+$ atuin stats
+# or
$ atuin stats all
+---------------------+-------+