Skip to content

Commit 68a9d43

Browse files
committed
update README with new mkdocs-material link
1 parent dc5ee39 commit 68a9d43

File tree

1 file changed

+19
-11
lines changed

1 file changed

+19
-11
lines changed

README.md

Lines changed: 19 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -12,24 +12,27 @@
1212

1313
## Setup
1414

15-
Install the plugin using pip:
15+
Install the plugin using `pip` with the following command:
1616

1717
```bash
1818
pip install mkdocs-git-revision-date-localized-plugin
1919
```
2020

21-
Activate the plugin in `mkdocs.yml`:
21+
Next, add the following lines to your `mkdocs.yml`:
2222

2323
```yaml
2424
plugins:
25+
- search
2526
- git-revision-date-localized
2627
```
2728
29+
> If you have no `plugins` entry in your config file yet, you'll likely also want to add the `search` plugin. MkDocs enables it by default if there is no `plugins` entry set.
30+
2831
## Usage
2932

3033
### In supported themes
3134

32-
- [mkdocs-material](https://squidfunk.github.io/mkdocs-material/) offers support for this plugin, see [setup instructions](https://squidfunk.github.io/mkdocs-material/extensions/revision-date/)
35+
- [mkdocs-material](https://squidfunk.github.io/mkdocs-material/) offers support for this plugin, see [setup instructions](https://squidfunk.github.io/mkdocs-material/plugins/revision-date/)
3336

3437
### In theme templates
3538

@@ -49,19 +52,18 @@ In your markdown files you can use `{{ git_revision_date_localized }}`:
4952
Last update: {{ git_revision_date_localized }}
5053
```
5154

52-
5355
## Options
5456

5557
### `type`
5658

57-
Set this option to one of `date`, `datetime`, `iso_date`, `iso_datetime` or `timeago`. Default is `date`. Example outputs:
59+
To change the date format, set the `type` parameter to one of `date`, `datetime`, `iso_date`, `iso_datetime` or `timeago`. Default is `date`. Example outputs:
5860

5961
```bash
60-
28 November, 2019 # type: date
61-
28 November, 2019 13:57:28 # type: datetime
62-
2019-11-28 # type: iso_date
63-
2019-11-28 13:57:26 # type: iso_datetime
64-
20 hours ago # type: timeago
62+
28 November, 2019 # type: date
63+
28 November, 2019 13:57:28 # type: datetime
64+
2019-11-28 # type: iso_date
65+
2019-11-28 13:57:26 # type: iso_datetime
66+
20 hours ago # type: timeago
6567
```
6668

6769
### `locale`
@@ -82,5 +84,11 @@ Example of setting both options:
8284
plugins:
8385
- git-revision-date-localized:
8486
type: timeago
85-
locale: nl
87+
locale: en
88+
```
89+
90+
Result:
91+
8692
```
93+
20 hours ago
94+
```

0 commit comments

Comments
 (0)