Skip to content

Commit

Permalink
Added tox.ini configuration to test init and build of the default sta…
Browse files Browse the repository at this point in the history
…rter kit on 2.7 and 3.2, plus all the changes it took to make this work.
  • Loading branch information
ironfroggy committed Nov 4, 2012
1 parent c5b0529 commit 301680e
Show file tree
Hide file tree
Showing 6 changed files with 16 additions and 5 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
*.py[oc]
*.sw[op]
testsite
2 changes: 1 addition & 1 deletion jules/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -400,7 +400,7 @@ def _render_with(self, engine, output_dir, template, output_path):
ensure_path(os.path.dirname(output_path))
if os.path.exists(output_path) and os.path.isdir(output_path):
output_path = os.path.join(output_path, 'index.html')
with open(output_path, 'w') as out:
with open(output_path, 'wb') as out:
out.write(r.encode('utf8'))
yield 'render', output_path

Expand Down
2 changes: 2 additions & 0 deletions jules/starters/default/contents/first-post.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
title: First Post
status: published
publish_time: !!timestamp '2012-06-23 10:00:00'
updated_time: !!timestamp '2012-06-23 10:00:00'
created_time: !!timestamp '2012-06-23 10:00:00'
template: post.j2
tags:
- test
2 changes: 1 addition & 1 deletion jules/starters/default/templates/post.j2
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@
{{ bundle.content|safe }}
</article>

{% if config.disqus.enabled_default and not bundle.meta.disqus_disable %}
{% if config.disqus and config.disqus.enabled_default and not bundle.meta.disqus_disable %}
<div id="disqus_thread"></div>
<script type="text/javascript">
var disqus_shortname = 'wwwironfroggycom'; // required: replace example with your forum shortname
Expand Down
10 changes: 7 additions & 3 deletions setup.py
Original file line number Diff line number Diff line change
@@ -1,18 +1,22 @@
#!/usr/bin/env python

from distutils.core import setup
from setuptools import setup, find_packages

INSTALL_REQUIRES = [
'straight.plugin',
'straight.command',
'pyyaml',
'jinja2',
'docutils',
]

setup(name='jules',
version='0.1.1',
version='0.2',
description='Yet Another Static Blog Generator I guess',
author='Calvin Spealman',
author_email='ironfroggy@gmail.com',
packages=['jules'],
packages=find_packages(),
include_package_data=True,
install_requires=INSTALL_REQUIRES,
classifiers=[
'Programming Language :: Python :: 2',
Expand Down
4 changes: 4 additions & 0 deletions tox.ini
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
[tox]
envlist = py27,py32
[testenv]
commands=./run_tests.sh

0 comments on commit 301680e

Please sign in to comment.