diff --git a/__init__.py b/__init__.py index e7dfa12..f82657e 100644 --- a/__init__.py +++ b/__init__.py @@ -6,6 +6,10 @@ from config import Config import os import re from os.path import isfile, abspath +from utils import pjoin2 +from utils import pjoin + + package_directory = os.path.dirname(os.path.abspath(__file__)) #cfg = Config(file('./config.cfg')) @@ -106,11 +110,6 @@ def get_flatpage(path): return (is_index, path, page) -def pjoin (rt,pth): - return u'{}/{}'.format(rt,pth) - -def pjoin2 (pth): - return u'/'.join(pth) or u'' def misskey(a,key): if not a.has_key(key): diff --git a/utils.py b/utils.py new file mode 100644 index 0000000..df36e62 --- /dev/null +++ b/utils.py @@ -0,0 +1,5 @@ +def pjoin (rt,pth): + return u'{}/{}'.format(rt,pth) + +def pjoin2 (pth): + return u'/'.join(pth) or u''