# HG changeset patch # User Steve Losh # Date 1261006477 18000 # Node ID 81d4da7f81f5eea7ead1007904a154a7568d4d93 Initial commit. diff -r 000000000000 -r 81d4da7f81f5 .hgignore --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/.hgignore Wed Dec 16 18:34:37 2009 -0500 @@ -0,0 +1,8 @@ +syntax: glob + +.DS_Store +*.pyc +*.log +out +deploy_tmp +.sass-cache diff -r 000000000000 -r 81d4da7f81f5 .venv --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/.venv Wed Dec 16 18:34:37 2009 -0500 @@ -0,0 +1,1 @@ +stevelosh-hyde diff -r 000000000000 -r 81d4da7f81f5 content/about/about.html --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/content/about/about.html Wed Dec 16 18:34:37 2009 -0500 @@ -0,0 +1,17 @@ +{% extends "_about.html" %} +{%hyde + title: "About" +%} +{% block article %} + +Hyde is a static website generator using django templates & an "extensible generation engine". + +Read more about Hyde [here:]({{content}}/{{links.introducing_hyde}}) + + +{% endblock %} + + + + + diff -r 000000000000 -r 81d4da7f81f5 content/archives/archives.html --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/content/archives/archives.html Wed Dec 16 18:34:37 2009 -0500 @@ -0,0 +1,5 @@ +{% extends "skeleton/_listing.html" %} +{%hyde + title: "Archives" + exclude: True +%} \ No newline at end of file diff -r 000000000000 -r 81d4da7f81f5 content/archives/firstpost.html --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/content/archives/firstpost.html Wed Dec 16 18:34:37 2009 -0500 @@ -0,0 +1,8 @@ +{% extends "_post.html" %} +{%hyde + title: "Welcome to Hyde!" + created: 2009-03-01 20:19:00 +%} +{% block article %} +Congratulations! You have successfully set up hyde! +{% endblock %} \ No newline at end of file diff -r 000000000000 -r 81d4da7f81f5 content/index.html --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/content/index.html Wed Dec 16 18:34:37 2009 -0500 @@ -0,0 +1,5 @@ +{% extends "skeleton/_index.html" %} +{%hyde + title: "Blog Posts" + listing: True +%} diff -r 000000000000 -r 81d4da7f81f5 layout/_about.html --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/layout/_about.html Wed Dec 16 18:34:37 2009 -0500 @@ -0,0 +1,14 @@ +{% extends "skeleton/_body.html" %} +{% block content_body %} +
+{% filter typogrify %} +{% markdown %} + +{% block article %} + +{% endblock %} + +{% endmarkdown %} +{% endfilter %} +
+{% endblock %} \ No newline at end of file diff -r 000000000000 -r 81d4da7f81f5 layout/_post.html --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/layout/_post.html Wed Dec 16 18:34:37 2009 -0500 @@ -0,0 +1,14 @@ +{% extends "skeleton/_body.html" %} +{% block content_body %} +
+{% filter typogrify %} +{% markdown %} +{% article %} +{% block article %} + +{% endblock %} +{% endarticle %} +{% endmarkdown %} +{% endfilter %} +
+{% endblock %} \ No newline at end of file diff -r 000000000000 -r 81d4da7f81f5 layout/skeleton/_atom.xml --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/layout/skeleton/_atom.xml Wed Dec 16 18:34:37 2009 -0500 @@ -0,0 +1,32 @@ + +{%spaceless%} + + {% block title %}{{site.name}} {{page.node.name}}{%endblock%} + {%block self_url %} + + {%endblock%} + {%block site_url %} + + {%endblock%}{%block feed_extra%}{%endblock%} + {{now|xmldatetime}} + {{site.full_url}} + {% for node_page in page.node.walk_pages %} + {% ifnotequal node_page page %} + {% if not node_page.listing and not node_page.exclude %} + + {{node_page.title}} + Lakshmi Vyas + + {{node_page.updated|default:node_page.created|xmldatetime}} + {{node_page.created|xmldatetime}} + {{node_page.full_url}} + {%block entry_extra%}{%endblock%} + + {%filter force_escape%}{% render_article node_page %}{%endfilter%} + + + {%endif%} + {%endifnotequal%} + {% endfor %} + +{%endspaceless%} \ No newline at end of file diff -r 000000000000 -r 81d4da7f81f5 layout/skeleton/_base.html --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/layout/skeleton/_base.html Wed Dec 16 18:34:37 2009 -0500 @@ -0,0 +1,27 @@ +{% extends "skeleton/_root.html" %} +{% block all %} + + + + + + {% block title %}{{site.name}}{% endblock %} + {% block feeds %} + + {% endblock %} + {% block css %} + + {% block extra_css %}{% endblock %}{% endblock %}{% block js %} + + {% block extra_js %}{% endblock %}{% endblock %} + + +{% include "skeleton/_header.html" %} +
+ {% block content %}{% endblock %} +
+{% include "skeleton/_footer.html" %} + + +{% endblock %} \ No newline at end of file diff -r 000000000000 -r 81d4da7f81f5 layout/skeleton/_body.html --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/layout/skeleton/_body.html Wed Dec 16 18:34:37 2009 -0500 @@ -0,0 +1,25 @@ +{% extends "skeleton/_base.html" %} +{% block title %}{{site.name}}{% endblock %} +{% block content %} +{% comment %}{% block breadcrumbs %}{% include "skeleton/_breadcrumbs.html"%}{% endblock %}{% endcomment %} +{% block nav %} + +{% endblock %} +{% block content_header %}{% ifnotequal page.module site.module %}

{{ page.title }}

{% endifnotequal %}{% endblock %} +{% block content_body %}{% endblock %} +{% endblock %} \ No newline at end of file diff -r 000000000000 -r 81d4da7f81f5 layout/skeleton/_breadcrumbs.html --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/layout/skeleton/_breadcrumbs.html Wed Dec 16 18:34:37 2009 -0500 @@ -0,0 +1,13 @@ +{% extends "skeleton/_root.html" %} +{% block all %} + + +{% endblock %} \ No newline at end of file diff -r 000000000000 -r 81d4da7f81f5 layout/skeleton/_footer.html --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/layout/skeleton/_footer.html Wed Dec 16 18:34:37 2009 -0500 @@ -0,0 +1,1 @@ + diff -r 000000000000 -r 81d4da7f81f5 layout/skeleton/_header.html --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/layout/skeleton/_header.html Wed Dec 16 18:34:37 2009 -0500 @@ -0,0 +1,5 @@ + diff -r 000000000000 -r 81d4da7f81f5 layout/skeleton/_index.html --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/layout/skeleton/_index.html Wed Dec 16 18:34:37 2009 -0500 @@ -0,0 +1,6 @@ +{% extends "skeleton/_body.html" %} +{% block content_body %} +{% for node in page.node.walk %} +{% include "skeleton/_innerindex.html" %} +{% endfor %} +{% endblock %} \ No newline at end of file diff -r 000000000000 -r 81d4da7f81f5 layout/skeleton/_innerindex.html --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/layout/skeleton/_innerindex.html Wed Dec 16 18:34:37 2009 -0500 @@ -0,0 +1,20 @@ +{% extends "skeleton/_root.html" %} +{% block all %} +{%spaceless%} +{% for list_page in node.pages %} +{% ifnotequal list_page node.listing_page %} +{% if not list_page.exclude %} +
+
+ {% with list_page.name_without_extension|remove_date_prefix|unslugify as default_title %} +

{{list_page.title|default_if_none:default_title }}

+ {% if list_page.created %}{{list_page.created}}{% endif %} + {%endwith%} +
+ {% render_article list_page %} +
+{%endif%} +{% endifnotequal %} +{% endfor %} +{%endspaceless%} +{% endblock %} \ No newline at end of file diff -r 000000000000 -r 81d4da7f81f5 layout/skeleton/_innerlisting.html --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/layout/skeleton/_innerlisting.html Wed Dec 16 18:34:37 2009 -0500 @@ -0,0 +1,16 @@ +{% extends "skeleton/_root.html" %} +{% block all %} +{%spaceless%} + +{%endspaceless%} +{% endblock %} \ No newline at end of file diff -r 000000000000 -r 81d4da7f81f5 layout/skeleton/_listing.html --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/layout/skeleton/_listing.html Wed Dec 16 18:34:37 2009 -0500 @@ -0,0 +1,8 @@ +{% extends "skeleton/_body.html"%} +{% block content_body %} +
+{% for node in page.node.walk %} +{% include "skeleton/_innerlisting.html" %} +{% endfor %} +
+{% endblock %} \ No newline at end of file diff -r 000000000000 -r 81d4da7f81f5 layout/skeleton/_root.html --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/layout/skeleton/_root.html Wed Dec 16 18:34:37 2009 -0500 @@ -0,0 +1,1 @@ +{% block all %}{% endblock %} \ No newline at end of file diff -r 000000000000 -r 81d4da7f81f5 media/css/base.css --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/media/css/base.css Wed Dec 16 18:34:37 2009 -0500 @@ -0,0 +1,128 @@ +* { + margin: 0; + padding: 0; +} + +body { + font-family: Arial, Helvetica, sans-serif; + color: black; + font-size: 1em; + line-height: 2em; +} + +h1 {font-size: 4em; line-height: 72px; font-weight: bold;} +h2 {font-size: 2em; line-height: 2em; font-weight: bold;} +h3 {font-size: 1.5em; line-height: 2em; font-weight: bold;} +h4 {font-size: 1.5em; line-height: 2em; font-weight: bold;} +h5 {font-size: 1em; line-height: 2em; font-weight: bold;} +h6 {font-size: 1em; line-height: 2em; font-weight: normal;} + +a { + text-decoration: none; + font-weight: bold; + color: #111; +} +a:hover { + color: #000; + border-bottom: 2px solid #cc0000; +} +a:visited { + color: #333; + font-style: italic; +} + +ul, ol { + margin-left: 0; + padding-left: 0; +} +li { + margin-bottom: 1em; + margin-left: 1em; + list-style-position: inside; +} + +#header { + height: 10em; +} +#header h1 { + margin: 0; + padding: 1em 0 0 0.5em; + line-height: 0; + font-size: 4em; + color: black; +} +#header h1:hover { + color: #cc0000; +} +#header a:visited { + font-style: normal; +} + +#nav ul { + padding: 0; + margin: 0; +} +#nav ul li { + padding: 0; + margin: 0; + display: inline; + list-style: none; + padding: 0.5em; + margin-right: 5px; + background: black; + color: white; +} +#nav ul li:hover { + border-bottom: 5px solid #cc0000; +} +#nav a { + color: white; + border: none; + font-style: normal; +} + +#content-header { + margin: 1em 0 0 0; +} + +#content { + margin: 0 2em 2em 2em; +} + +ul#archives { + list-style: none; +} +ul#archives li { + font-size: 1.5em; +} + +#footer { + text-align: center; + font-size: 0.6em; +} + +div.article { + margin-top: 2em; +} + +.title { + margin-bottom: 1.67em; + border-bottom: 6px solid #cccccc; +} +.title h3 { + display: inline; + line-height: 1em; +} +.title span { + font-size: 0.67em; + line-height: 1em; + padding: 1em; + float: right; +} +.title a:hover { + border: none; +} +.title a:visited { + color: #111; + font-style: normal; +} \ No newline at end of file diff -r 000000000000 -r 81d4da7f81f5 settings.py --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/settings.py Wed Dec 16 18:34:37 2009 -0500 @@ -0,0 +1,111 @@ +import os + +ROOT_PATH = os.path.abspath(os.path.dirname(__file__)) + +#Directories +LAYOUT_DIR = os.path.join(ROOT_PATH, 'layout') +CONTENT_DIR = os.path.join(ROOT_PATH, 'content') +MEDIA_DIR = os.path.join(ROOT_PATH, 'media') +DEPLOY_DIR = os.path.join(ROOT_PATH, 'deploy') +TMP_DIR = os.path.join(ROOT_PATH, 'deploy_tmp') +BACKUPS_DIR = os.path.join(ROOT_PATH, 'backups') + +BACKUP = False + +SITE_ROOT = "/" +SITE_WWW_URL = "http://www.yoursite.com" +SITE_NAME = "Hyde" + +#Url Configuration +GENERATE_ABSOLUTE_FS_URLS = False + +# Clean urls causes Hyde to generate urls without extensions. Examples: +# http://example.com/section/page.html becomes +# http://example.com/section/page/, and the listing for that section becomes +# http://example.com/section/ +# The built-in CherryPy webserver is capable of serving pages with clean urls +# without any additional configuration, but Apache will need to use Mod_Rewrite +# to map the clean urls to the actual html files. The HtaccessGenerator site +# post processor is capable of automatically generating the necessary +# RewriteRules for use with Apache. +GENERATE_CLEAN_URLS = False + +# A list of filenames (without extensions) that will be considered listing +# pages for their enclosing folders. +# LISTING_PAGE_NAMES = ['index'] +LISTING_PAGE_NAMES = [] + +# Determines whether or not to append a trailing slash to generated urls when +# clean urls are enabled. +APPEND_SLASH = False + +# {folder : extension : (processors)} +# The processors are run in the given order and are chained. +# Only a lone * is supported as an indicator for folders. Path +# should be specified. No wildcard card support yet. + +# Starting under the media folder. For example, if you have media/css under +# your site root,you should specify just css. If you have media/css/ie you +# should specify css/ie for the folder name. css/* is not supported (yet). + +# Extensions do not support wildcards. + +MEDIA_PROCESSORS = { + '*':{ + '.css':('hydeengine.media_processors.TemplateProcessor', + 'hydeengine.media_processors.YUICompressor',), + '.ccss':('hydeengine.media_processors.TemplateProcessor', + 'hydeengine.media_processors.CleverCSS', + 'hydeengine.media_processors.YUICompressor',), + '.hss':( + 'hydeengine.media_processors.TemplateProcessor', + 'hydeengine.media_processors.HSS', + 'hydeengine.media_processors.YUICompressor',), + '.js':( + 'hydeengine.media_processors.TemplateProcessor', + 'hydeengine.media_processors.YUICompressor',) + } +} + +CONTENT_PROCESSORS = {} + +SITE_POST_PROCESSORS = { + # 'media/js': { + # 'hydeengine.site_post_processors.FolderFlattener' : { + # 'remove_processed_folders': True, + # 'pattern':"*.js" + # } + # } +} + +CONTEXT = { + 'GENERATE_CLEAN_URLS': GENERATE_CLEAN_URLS +} + +FILTER = { + 'include': (".htaccess",), + 'exclude': (".*","*~") +} + + +#Processor Configuration + +# path for YUICompressor, or None if you don't +# want to compress JS/CSS. Project homepage: +# http://developer.yahoo.com/yui/compressor/ +YUI_COMPRESSOR = "./lib/yuicompressor-2.4.1.jar" +#YUI_COMPRESSOR = None + +# path for HSS, which is a preprocessor for CSS-like files (*.hss) +# project page at http://ncannasse.fr/projects/hss +#HSS_PATH = "./lib/hss-1.0-osx" +HSS_PATH = None # if you don't want to use HSS + +#Django settings + +TEMPLATE_DIRS = (LAYOUT_DIR, CONTENT_DIR, TMP_DIR, MEDIA_DIR) + +INSTALLED_APPS = ( + 'hydeengine', + 'django.contrib.webdesign', +)