##// END OF EJS Templates
use less from components
MinRK -
Show More
@@ -1,20 +1,21 b''
1 1 """ fabfile to prepare the notebook """
2 2
3 3 from fabric.api import local,lcd
4 4 from fabric.utils import abort
5 5 import os
6 6
7 7 static_dir = 'static'
8 8 components_dir = os.path.join(static_dir, 'components')
9 9
10 10
11 11 def css(minify=True):
12 12 """generate the css from less files"""
13 13 if minify not in ['True', 'False', True, False]:
14 14 abort('minify must be Boolean')
15 15 minify = (minify in ['True',True])
16 16
17 17 min_flag= '-x' if minify is True else ''
18 lessc = os.path.join('components', 'less.js', 'bin', 'lessc')
18 19 with lcd(static_dir):
19 local('lessc {min_flag} less/style.less css/style.min.css'.format(min_flag=min_flag))
20 local('{lessc} {min_flag} less/style.less css/style.min.css'.format(**locals()))
20 21
General Comments 0
You need to be logged in to leave comments. Login now