Skip to content

Foundation 5, SCSS, HAML and Coffee Script. Modular structure for css/scss files. Rails like assets structure.

Notifications You must be signed in to change notification settings

Velocis/middleman-foundation5-basic

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

45 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Middleman Template: foundation5-basic

foundation5-basic is a Middleman project template for the ZURB Foundation 5 Framework. One objective is to have a basic project skeleton, that is structured similar to a Ruby on Rails project. This makes it easy to switch between Middleman and Rails projects.

This project comes with some example files which uses:

  1. SASS
  2. HAML
  3. Coffee Script
  4. A modular structure for the css/scss files

Installation

Make sure to have:

  1. ruby
  2. git
  3. middleman (gem install middleman)
  4. bower (npm install -g bower) - npm depends on node.js so be sure to have it installed (e.g. via homebrew brew install node)

Clone this repository to ~/.middleman

  1. git clone git://github.com/RalphAtHamburg/middleman-foundation5-basic.git ~/.middleman/foundation5-basic

Then create a new project using the foundation5-basic template.

  1. middleman init my_new_project --template=foundation5-basic
  2. cd my_new_project

Starting with Foundation 5, Zurb uses bower for the package management. The bower install command will create a folder bower_components with all needed files inside the source folder of Middleman. To prevent your git repository being polluted by changes to third party components, this directory is not tracked by git.

  1. $ bower install

Start the middleman server:

  1. $ bundle exec middleman

Now you can start editing on the source directory and watch live changes on localhost:4567.

File Structure

|_ source/
|  |_ assets/                               # Assets can be images, js/coffee files and stylesheets
|  |  |_ images/                            # All images
|  |  |  |_ pic.jpg                         # Example image  
|  |  |_ javascripts/                       # All js or coffee files
|  |  |  |_ all.js                          # This is a manifest file. The listed files are included in the body section
|  |  |  |_ before.js                       # This is a manifest file. The listed files are included in the header section
|  |  |  |_ _app.js.coffee                  # All the js/coffee stuff for the application
|  |  |  |  |_ vendor/                      # Third party libs. Will be loaded throught the require statement in all.js
|  |  |_ stylesheets/                       # All stylesheets
|  |  |  |_ app.css.scss                    # Manifest file with all imports
|  |  |  |_ foundation_and_overrides.scss   # Foundation defaults to overwrite
|  |  |  |_ base/                           # Base modules like color, typography. Add your own files here
|  |  |  |  |_ _colors.css.scss             # Colors
|  |  |  |  |_ _mixins.css.scss             # Mixins
|  |  |  |  |_ _typography.css.scss         # Typography, fonts
|  |  |  |_ modules/                        # Components like navigation, header, form or product. Add your own files here.
|  |  |  |  |_ _layout.css.scss             # Layout is just a module like all the others
|  |  |  |  |_ _sample.css.scss             # Sample module
|  |_ layouts/                              # Layouts
|  |_ bower_components/                     # Will be generated by bower packet manager  
|  |_ partials/                             # All partials
|  |  |_ _footer.haml                       # Example partial    
|  |_ index.haml                            # Homepage
|  |_ page-1.haml                           # Example page
|_ .gitignore                               # Git ignore
|_ config.rb                                # Middleman configuration
|_ bower.json                               # The bower configuration file to load the foundation components
|_ Gemfile                                  # All gems
|_ Gemfile.lock                             # Snapshot of all your required gems and their dependencies
|_ README.md                                # This README

ZURB Foundation License

Copyright (c) 2011 ZURB, http://www.zurb.com/

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

The MIT License (MIT)

Copyright (c) 2013 Horacio Herrera

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

About

Foundation 5, SCSS, HAML and Coffee Script. Modular structure for css/scss files. Rails like assets structure.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • CSS 82.4%
  • Ruby 15.8%
  • CoffeeScript 1.5%
  • JavaScript 0.3%