Mercurial > moin > 1.9
annotate wikiconfig.py @ 5210:e167f58601ef
pdf indexing filter: use quiet operation to work around problems
author | Thomas Waldmann <tw AT waldmann-edv DOT de> |
---|---|
date | Tue, 06 Oct 2009 21:31:57 +0200 |
parents | d57cfa1a3724 |
children | 12d27670e274 2cabbada21f4 |
rev | line source |
---|---|
1597
bbe187af4fc0
integrated MMDE (build scripts need more work)
Thomas Waldmann <tw AT waldmann-edv DOT de>
parents:
diff
changeset
|
1 # -*- coding: iso-8859-1 -*- |
bbe187af4fc0
integrated MMDE (build scripts need more work)
Thomas Waldmann <tw AT waldmann-edv DOT de>
parents:
diff
changeset
|
2 """MoinMoin Desktop Edition (MMDE) - Configuration |
bbe187af4fc0
integrated MMDE (build scripts need more work)
Thomas Waldmann <tw AT waldmann-edv DOT de>
parents:
diff
changeset
|
3 |
bbe187af4fc0
integrated MMDE (build scripts need more work)
Thomas Waldmann <tw AT waldmann-edv DOT de>
parents:
diff
changeset
|
4 ONLY to be used for MMDE - if you run a personal wiki on your notebook or PC. |
bbe187af4fc0
integrated MMDE (build scripts need more work)
Thomas Waldmann <tw AT waldmann-edv DOT de>
parents:
diff
changeset
|
5 |
bbe187af4fc0
integrated MMDE (build scripts need more work)
Thomas Waldmann <tw AT waldmann-edv DOT de>
parents:
diff
changeset
|
6 This is NOT intended for internet or server or multiuser use due to relaxed security settings! |
bbe187af4fc0
integrated MMDE (build scripts need more work)
Thomas Waldmann <tw AT waldmann-edv DOT de>
parents:
diff
changeset
|
7 """ |
1599
c001386fc59b
fix moin.py and wikiconfig.py, move MMDE wikiconfig.py to toplevel dir
Thomas Waldmann <tw AT waldmann-edv DOT de>
parents:
1597
diff
changeset
|
8 import sys, os |
c001386fc59b
fix moin.py and wikiconfig.py, move MMDE wikiconfig.py to toplevel dir
Thomas Waldmann <tw AT waldmann-edv DOT de>
parents:
1597
diff
changeset
|
9 from MoinMoin.config.multiconfig import DefaultConfig |
1597
bbe187af4fc0
integrated MMDE (build scripts need more work)
Thomas Waldmann <tw AT waldmann-edv DOT de>
parents:
diff
changeset
|
10 |
2286
01f05e74aa9c
Big PEP8 and whitespace cleanup
Thomas Waldmann <tw AT waldmann-edv DOT de>
parents:
2244
diff
changeset
|
11 |
3423
6fa56b0f0de4
re-add wikiconfig_local a bit differently
Johannes Berg <johannes AT sipsolutions DOT net>
parents:
3173
diff
changeset
|
12 class LocalConfig(DefaultConfig): |
1597
bbe187af4fc0
integrated MMDE (build scripts need more work)
Thomas Waldmann <tw AT waldmann-edv DOT de>
parents:
diff
changeset
|
13 # vvv DON'T TOUCH THIS EXCEPT IF YOU KNOW WHAT YOU DO vvv |
bbe187af4fc0
integrated MMDE (build scripts need more work)
Thomas Waldmann <tw AT waldmann-edv DOT de>
parents:
diff
changeset
|
14 moinmoin_dir = os.path.abspath(os.path.normpath(os.path.dirname(sys.argv[0]))) |
bbe187af4fc0
integrated MMDE (build scripts need more work)
Thomas Waldmann <tw AT waldmann-edv DOT de>
parents:
diff
changeset
|
15 data_dir = os.path.join(moinmoin_dir, 'wiki', 'data') |
bbe187af4fc0
integrated MMDE (build scripts need more work)
Thomas Waldmann <tw AT waldmann-edv DOT de>
parents:
diff
changeset
|
16 data_underlay_dir = os.path.join(moinmoin_dir, 'wiki', 'underlay') |
bbe187af4fc0
integrated MMDE (build scripts need more work)
Thomas Waldmann <tw AT waldmann-edv DOT de>
parents:
diff
changeset
|
17 |
bbe187af4fc0
integrated MMDE (build scripts need more work)
Thomas Waldmann <tw AT waldmann-edv DOT de>
parents:
diff
changeset
|
18 DesktopEdition = True # give all local users full powers |
bbe187af4fc0
integrated MMDE (build scripts need more work)
Thomas Waldmann <tw AT waldmann-edv DOT de>
parents:
diff
changeset
|
19 acl_rights_default = u"All:read,write,delete,revert,admin" |
1602
f5773070c915
mmde: disable surge protection
Thomas Waldmann <tw AT waldmann-edv DOT de>
parents:
1600
diff
changeset
|
20 surge_action_limits = None # no surge protection |
1597
bbe187af4fc0
integrated MMDE (build scripts need more work)
Thomas Waldmann <tw AT waldmann-edv DOT de>
parents:
diff
changeset
|
21 sitename = u'MoinMoin DesktopEdition' |
5138
d57cfa1a3724
prepare 1.8.5 release: bump version number, add mig script
Thomas Waldmann <tw AT waldmann-edv DOT de>
parents:
4909
diff
changeset
|
22 logo_string = u'<img src="/moin_static185/common/moinmoin.png" alt="MoinMoin Logo">' |
1597
bbe187af4fc0
integrated MMDE (build scripts need more work)
Thomas Waldmann <tw AT waldmann-edv DOT de>
parents:
diff
changeset
|
23 page_front_page = u'FrontPage' # change to some better value |
bbe187af4fc0
integrated MMDE (build scripts need more work)
Thomas Waldmann <tw AT waldmann-edv DOT de>
parents:
diff
changeset
|
24 # ^^^ DON'T TOUCH THIS EXCEPT IF YOU KNOW WHAT YOU DO ^^^ |
bbe187af4fc0
integrated MMDE (build scripts need more work)
Thomas Waldmann <tw AT waldmann-edv DOT de>
parents:
diff
changeset
|
25 |
3423
6fa56b0f0de4
re-add wikiconfig_local a bit differently
Johannes Berg <johannes AT sipsolutions DOT net>
parents:
3173
diff
changeset
|
26 # Add your configuration items here. |
3873
e5a9570d3001
secrets configuration refactored - see the snippet for an example usage
Thomas Waldmann <tw AT waldmann-edv DOT de>
parents:
3762
diff
changeset
|
27 secrets = 'This string is NOT a secret, please make up your own, long, random secret string!' |
3423
6fa56b0f0de4
re-add wikiconfig_local a bit differently
Johannes Berg <johannes AT sipsolutions DOT net>
parents:
3173
diff
changeset
|
28 |
6fa56b0f0de4
re-add wikiconfig_local a bit differently
Johannes Berg <johannes AT sipsolutions DOT net>
parents:
3173
diff
changeset
|
29 |
6fa56b0f0de4
re-add wikiconfig_local a bit differently
Johannes Berg <johannes AT sipsolutions DOT net>
parents:
3173
diff
changeset
|
30 # DEVELOPERS! Do not add your configuration items there, |
6fa56b0f0de4
re-add wikiconfig_local a bit differently
Johannes Berg <johannes AT sipsolutions DOT net>
parents:
3173
diff
changeset
|
31 # you could accidentally commit them! Instead, create a |
6fa56b0f0de4
re-add wikiconfig_local a bit differently
Johannes Berg <johannes AT sipsolutions DOT net>
parents:
3173
diff
changeset
|
32 # wikiconfig_local.py file containing this: |
6fa56b0f0de4
re-add wikiconfig_local a bit differently
Johannes Berg <johannes AT sipsolutions DOT net>
parents:
3173
diff
changeset
|
33 # |
6fa56b0f0de4
re-add wikiconfig_local a bit differently
Johannes Berg <johannes AT sipsolutions DOT net>
parents:
3173
diff
changeset
|
34 # from wikiconfig import LocalConfig |
6fa56b0f0de4
re-add wikiconfig_local a bit differently
Johannes Berg <johannes AT sipsolutions DOT net>
parents:
3173
diff
changeset
|
35 # |
6fa56b0f0de4
re-add wikiconfig_local a bit differently
Johannes Berg <johannes AT sipsolutions DOT net>
parents:
3173
diff
changeset
|
36 # class Config(LocalConfig): |
6fa56b0f0de4
re-add wikiconfig_local a bit differently
Johannes Berg <johannes AT sipsolutions DOT net>
parents:
3173
diff
changeset
|
37 # configuration_item_1 = 'value1' |
6fa56b0f0de4
re-add wikiconfig_local a bit differently
Johannes Berg <johannes AT sipsolutions DOT net>
parents:
3173
diff
changeset
|
38 # |
6fa56b0f0de4
re-add wikiconfig_local a bit differently
Johannes Berg <johannes AT sipsolutions DOT net>
parents:
3173
diff
changeset
|
39 |
6fa56b0f0de4
re-add wikiconfig_local a bit differently
Johannes Berg <johannes AT sipsolutions DOT net>
parents:
3173
diff
changeset
|
40 try: |
6fa56b0f0de4
re-add wikiconfig_local a bit differently
Johannes Berg <johannes AT sipsolutions DOT net>
parents:
3173
diff
changeset
|
41 from wikiconfig_local import Config |
6fa56b0f0de4
re-add wikiconfig_local a bit differently
Johannes Berg <johannes AT sipsolutions DOT net>
parents:
3173
diff
changeset
|
42 except ImportError, err: |
6fa56b0f0de4
re-add wikiconfig_local a bit differently
Johannes Berg <johannes AT sipsolutions DOT net>
parents:
3173
diff
changeset
|
43 if not str(err).endswith('wikiconfig_local'): |
6fa56b0f0de4
re-add wikiconfig_local a bit differently
Johannes Berg <johannes AT sipsolutions DOT net>
parents:
3173
diff
changeset
|
44 raise |
6fa56b0f0de4
re-add wikiconfig_local a bit differently
Johannes Berg <johannes AT sipsolutions DOT net>
parents:
3173
diff
changeset
|
45 Config = LocalConfig |