diff --git a/requirements.txt b/requirements.txt new file mode 100644 index 0000000000..4cbb27f441 --- /dev/null +++ b/requirements.txt @@ -0,0 +1,16 @@ +Jinja2==2.7.1 +MarkupSafe==0.18 +MySQL-python==1.2.4 +chardet==2.1.1 +dropbox==1.6 +google-api-python-client==1.2 +httplib2==0.8 +markdown2==2.1.0 +mysql-utilities==1.3.5 +pygeoip==0.2.7 +python-dateutil==2.1 +python-memcached==1.53 +pytz==2013b +requests==1.2.3 +six==1.4.0 +termcolor==1.1.0 \ No newline at end of file diff --git a/website/doctype/website_settings/make_web_include_files.py b/website/doctype/website_settings/make_web_include_files.py index 693d5c7fea..f20dd812a6 100644 --- a/website/doctype/website_settings/make_web_include_files.py +++ b/website/doctype/website_settings/make_web_include_files.py @@ -6,24 +6,22 @@ import webnotes def make(): from webnotes.webutils import get_home_page + from webnotes.utils import get_path if not webnotes.conn: webnotes.connect() home_page = get_home_page() - fname = 'js/wn-web.js' - if os.path.basename(os.path.abspath('.'))!='public': - fname = os.path.join('public', fname) - + if not os.path.exists(get_path("public", "js")): + os.makedirs(get_path("public", "js")) + fname = os.path.join(get_path("public", "js", "wn-web.js")) with open(fname, 'w') as f: f.write(get_web_script()) - fname = 'css/wn-web.css' - if os.path.basename(os.path.abspath('.'))!='public': - fname = os.path.join('public', fname) - - # style - wn.css + if not os.path.exists(get_path("public", "css")): + os.makedirs(get_path("public", "css")) + fname = os.path.join(get_path("public", "css", "wn-web.css")) with open(fname, 'w') as f: f.write(get_web_style())