projects
/
cmless
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
tags
|
clone url
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
765a8ad
)
Added URL 'un'parsing to change things like "%20" to spaces for use with
author
Aaron Taylor
<ataylor@subgeniuskitty.com>
Mon, 8 Jan 2018 05:36:37 +0000
(21:36 -0800)
committer
Aaron Taylor
<ataylor@subgeniuskitty.com>
Mon, 8 Jan 2018 05:36:37 +0000
(21:36 -0800)
filesystem lookups.
bin/cmless.py
patch
|
blob
|
blame
|
history
diff --git
a/bin/cmless.py
b/bin/cmless.py
index
44399c9
..
500edb6
100755
(executable)
--- a/
bin/cmless.py
+++ b/
bin/cmless.py
@@
-4,7
+4,7
@@
# See LICENSE file for copyright and license details.
# Python imports
# See LICENSE file for copyright and license details.
# Python imports
-import sys, os
+import sys, os
, urllib.parse
# CMless imports
import config, misc, template
# CMless imports
import config, misc, template
@@
-14,6
+14,7
@@
def main():
if os.environ['REQUEST_URI'][-1] == "/":
os.environ['REQUEST_URI'] = os.environ['REQUEST_URI'] + config.default_page
if os.environ['REQUEST_URI'][-1] == "/":
os.environ['REQUEST_URI'] = os.environ['REQUEST_URI'] + config.default_page
+ os.environ['REQUEST_URI'] = urllib.parse.unquote(os.environ['REQUEST_URI'])
content = misc.load_file(config.site_template_prefix + "/" + config.template_file)
content = template.page_title(content)
content = misc.load_file(config.site_template_prefix + "/" + config.template_file)
content = template.page_title(content)