Permalink
Browse files

Take 1

* Setup to use Haml and Sass
* Requiring grid-coordinates
  • Loading branch information...
1 parent 643d23c commit 99cdf7d6a345fcb8e18ed6b23ba64954de928217 Adam Stacoviak committed Oct 10, 2009
View
3 .gitignore
@@ -0,0 +1,3 @@
+.DS_Store
+.sass-cache
+output/*
View
16 Rules
@@ -1,12 +1,22 @@
#!/usr/bin/env ruby
+require 'compass'
+Compass.configuration.parse 'config/compass.config'
+
+compile '/stylesheets/*/' do
+ filter :sass, Compass.sass_engine_options
+end
+
+route '/stylesheets/*/' do
+ item.identifier.chop + '.css'
+end
compile '*' do
- filter :haml
- layout 'default'
+ filter :haml
+ layout 'default'
end
route '*' do
item.identifier + 'index.html'
end
-layout '*', :haml
+layout '*', :haml, :format => :html5
View
8 config/compass.config
@@ -0,0 +1,8 @@
+require 'grid-coordinates'
+
+http_path = "/"
+project_path = "."
+css_dir = "output/stylesheets"
+sass_dir = "content/stylesheets"
+images_dir = "output/images"
+output_style = :expanded
View
18 content/index.haml
@@ -1,18 +1,4 @@
%h1
- A Brand New nanoc Site
+ Nanoc Template
%p
- You've just created a new nanoc site. The page you are looking at right now is the home page for your site (and it's probably the only page).
-%p
- To get started, consider replacing this default homepage with your own customized homepage. Some pointers on how to do so:
-%ul
- %li
- %p
- %strong
- Change this page's content
- by editing "content.html" file in the "content" directory. This is the actual page content, and therefore doesn't include the header, sidebar or style information (those are part of the layout).
- %li
- %p
- Change the layout, which is the "default.txt" file in the "layouts/default" directory, and create something unique (and hopefully less bland).
- %p
- If you need any help with customizing your nanoc web site, be sure to check out the documentation (see sidebar), and be sure to subscribe to the discussion group (also see sidebar). Enjoy!
- %p Lorem ipsum dolor sit amet, consectetur adipisicing elit.
+ This is intended to be a nice starting point for a Nanoc site with support for Haml, Sass and Compass out of the box.
View
11 content/stylesheets/styles.sass
@@ -0,0 +1,11 @@
+@import compass/utilities
+@import grid-coordinates
+
+body
+ font-family: Arial, Verdana, Helvetica, Times, "Times New Roman", sans-serif
+ padding-top: 30px
+ padding-left: 50px
+ p
+ font-size: 16px
+ h1
+ margin-top: 0
View
2 content/stylesheets/styles.yaml
@@ -0,0 +1,2 @@
+---
+filter: sass
View
28 layouts/default.html
@@ -2,29 +2,7 @@
%html
%head
%title
- A Brand New nanoc Site - <%= @item[:title] %>
- %link{ :href => "/style.css", :rel => "stylesheet", :type => "text/css", :media => "screen" }
+ = "Nanoc Template - #{@item[:title]}"
+ %link{ :href => "stylesheets/styles.css", :rel => "stylesheet", :type => "text/css", :media => "screen" }
%body
- #main
- #sidebar
- %h2
- Documentation
- %ul
- %li
- %a{ :href => "http://nanoc.stoneship.org/help/tutorial/" }
- Tutorial
- %li
- %a{ :href => "http://nanoc.stoneship.org/help/manual/" }
- Manual
- %h2
- Community
- %ul
- %li
- %a{ :href => "http://groups.google.com/group/nanoc/" }
- Discussion Group
- %li
- %a{ :href => "http://groups.google.com/group/nanoc-es/" }
- Spanish Discussion Group
- %li
- %a{ :href => "http://projects.stoneship.org/trac/nanoc/" }
- Wiki
+ = yield
View
49 output/index.html
@@ -1,49 +0,0 @@
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
-<html>
- <head>
- <title>
- A Brand New nanoc Site - <%= @item[:title] %>
- </title>
- <link href='/style.css' media='screen' rel='stylesheet' type='text/css' />
- </head>
- <body>
- <div id='main'></div>
- <div id='sidebar'>
- <h2>
- Documentation
- </h2>
- <ul>
- <li>
- <a href='http://nanoc.stoneship.org/help/tutorial/'>
- Tutorial
- </a>
- </li>
- <li>
- <a href='http://nanoc.stoneship.org/help/manual/'>
- Manual
- </a>
- </li>
- </ul>
- <h2>
- Community
- </h2>
- <ul>
- <li>
- <a href='http://groups.google.com/group/nanoc/'>
- Discussion Group
- </a>
- </li>
- <li>
- <a href='http://groups.google.com/group/nanoc-es/'>
- Spanish Discussion Group
- </a>
- </li>
- <li>
- <a href='http://projects.stoneship.org/trac/nanoc/'>
- Wiki
- </a>
- </li>
- </ul>
- </div>
- </body>
-</html>
View
BIN tmp/dependencies
Binary file not shown.

0 comments on commit 99cdf7d

Please sign in to comment.