allenm / python-live-stylus

Convert stylus to css real time. Easily used with any web framwork.
MIT License
8 stars 3 forks source link

SyntaxError with live_stylus #2

Open roryjarrard opened 9 years ago

roryjarrard commented 9 years ago

I'm getting the following error when using live_stylus Traceback (most recent call last): File "app.py", line 3, in <module> from live_stylus import ConvStylus File "/home/rjarrard/projects/roryj-flask/core/lib/python3.4/site-packages/live_stylus/__init__.py", line 26 print 'Compile the file: %s' % ( filename ) ^ SyntaxError: invalid syntax The caret is pointing to the ending single quote after the %s.

Here is my app.py

` from flask import Flask from flask import render_template from live_stylus import ConvStylus

app = Flask(name)

app.debug = True

app.jinja_env.add_extension('pyjade.ext.jinja.PyJadeExtension')

app.config['SECRET_KEY'] = 'hxbBWZG2jwhJyS2ahjApe2Rr'

@app.route('/') def index(): title = 'Index' return render_template('index.jade', title=title)

@app.route('/tutorials') def tutorials(): title = 'Tutorials' return render_template('tutorials.jade', title=title)

if name == 'main': ConvStylus() app.run() `

and static/css/main.styl (this is 3 lines but the editor keeps rendering as one line) `

container

min-height: 30rem background: red `

Any help would be appreciated. Thanks!

allenm commented 9 years ago

Sorry , I have not been used python for two years . May be you should use some other library , or fix it by yourself.