Skip to content

Commit 0e083d8

Browse files
Oleksandr Kulkovadamant-pwn
authored andcommitted
Update contribs.md
1 parent 1b0748b commit 0e083d8

File tree

1 file changed

+60
-5
lines changed

1 file changed

+60
-5
lines changed

src/contrib.md

Lines changed: 60 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -39,17 +39,51 @@ For advanced Markdown features of Material for MkDocs see their [reference pages
3939

4040
However not everything of the features should be used, and some of the features are not enabled or require a paid subscription.
4141

42+
To distinguish original and translatory articles, they should be marked with corresponding tags. For original articles, it's
43+
44+
```md
45+
---
46+
tags:
47+
- Original
48+
---
49+
```
50+
51+
And for translated articles, it's
52+
53+
```md
54+
---
55+
tags:
56+
- Translated
57+
e_maxx_link: ...
58+
---
59+
```
60+
61+
Here, instead of `...` one should place the last part of the link to the original article. E.g. for [Euler function article](http://e-maxx.ru/algo/euler_function) it should be
62+
63+
64+
```md
65+
---
66+
tags:
67+
- Translated
68+
e_maxx_link: euler_function
69+
---
70+
```
71+
4272
By default the first header (`# header`) will be also the HTML title of the article. In case the header contains a math formula, you can define a different HTML title with:
4373

4474
```markdown
4575
---
76+
tags:
77+
- ...
4678
title: Alternative HTML title
4779
---
4880
# Proof of $a^2 + b^2 = c^2$
4981

5082
remaining article
5183
```
5284

85+
86+
5387
## Some conventions
5488

5589
* We have agreed as of issue [#83](https://github.com/e-maxx-eng/e-maxx-eng/issues/83) to express binomial coefficients with `\binom{n}{k}` instead of `C_n^k`. The first one renders as $\binom{n}{k}$ and is a more universal convention. The second would render as $C_n^k$.
@@ -60,16 +94,37 @@ Try to add problems in ascending order of their difficulty. If you don't have en
6094

6195
## Local development
6296

63-
You can render the pages very easily also locally.
64-
All you need is Python, with the installed `mkdocs-material` package.
97+
You can render the pages locally. All you need is Python, with the installed `mkdocs-material` package.
6598

6699
```console
67-
$ git clone --recursive https://github.com/e-maxx-eng/e-maxx-eng.git
68-
$ cd e-maxx-eng
69-
$
100+
$ git clone --recursive https://github.com/e-maxx-eng/e-maxx-eng.git && cd e-maxx-eng
101+
$ scripts/install-mkdocs.sh # requires pip installation
70102
$ mkdocs serve
71103
```
72104

105+
Note that some features are disabled by default for local builds.
106+
107+
### Git revision date plugin
108+
109+
Disabled because it might produce errors when there are uncommitted changes in the working tree.
110+
111+
To enable it, set the environment variable `MKDOCS_ENABLE_GIT_REVISION_DATE` to `True`:
112+
113+
```console
114+
$ export MKDOCS_ENABLE_GIT_REVISION_DATE=True
115+
```
116+
117+
### Git committers plugin
118+
119+
Disabled because it takes a while to prepare and also requires Github personal access token to work with Github APIs.
120+
121+
To enable it, set the environment variable `MKDOCS_ENABLE_GIT_COMMITTERS` to `True` and store your personal access token in the environment variable `MKDOCS_GIT_COMMITTERS_APIKEY`. You can generate the token [here](https://github.com/settings/tokens). Note that you only need the public access, so you shouldn't give the token any permissions.
122+
123+
```console
124+
$ export MKDOCS_ENABLE_GIT_COMMITTERS=True
125+
$ export MKDOCS_GIT_COMMITTERS_APIKEY= # put your PAT here
126+
```
127+
73128
## Tests
74129

75130
If your article involves code snippets, then it would be great you also contribute tests for them.

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy