-
Notifications
You must be signed in to change notification settings - Fork 0
/
config.py
80 lines (62 loc) · 1.78 KB
/
config.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
"""
Copyright 2024 Nekoweb Wiki
This software is licensed under the 3-clause BSD license.
You should have recieved a copy of such license with this software,
if you did not, a copy can be found at the following
https://opensource.org/license/BSD-3-Clause
Otherwise, a copy of this license can be found in the root directory
of this project.
"""
from re import compile as ReCompile, X as ReX
OUTPUT_DIR = "build"
LINK_PATTERS = [
(
ReCompile(r"""\b((?:https?://|(?<!//)www\.)\w[\w_\-]*(?:\.\w[\w_\-]*)*[^<>\s"']*(?<![?!.,:*_~);])(?=[?!.,:*_~);]?(?:[<\s]|$)))""", ReX),
r"\1"
)
]
CODE_REPOSITORY = "https://github.com/NekowebWiki/WikiGen"
SOURCE_PREFIX = "/editor.html?path="
SOURCE_SUFFIX = ""
COMMITS_PREFIX = CODE_REPOSITORY + "/commits/main/"
COMMITS_SUFFIX = ""
COMMIT_PREFIX = CODE_REPOSITORY + "/commit/"
COMMIT_SUFFIX = ""
DIRECTORIES = {
"static": {
"out": "",
"static": True
},
"content": {
"out": "w",
"static": False,
"articledir": True
},
"headpages": {
"out": "",
"static": False,
"articledir": False
},
"images": {
"out": "i",
"static": True
},
"branding": {
"out": "",
"static": True
}
}
ADD_FILES = {
"BSD-3-CLAUSE.txt": "",
"CC_BY-SA.txt": "",
"CNPL.txt": "",
}
SITE_URL = "https://wiki.nekoweb.org/"
COPYRIGHT_NOTICE = """Copyright 2024 Nekoweb Wiki
This software is licensed under the 3-clause BSD license.
You should have recieved a copy of such license with this software,
if you did not, a copy can be found at the following
https://opensource.org/license/BSD-3-Clause
Otherwise, a copy of the license can be found in the root directory
of the source files, see
https://github.com/NekowebWiki/WikiGen"""