Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

cabin

Package Overview
Dependencies
Maintainers
3
Versions
124
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

cabin

Static site generator scaffolding for grunt

  • 0.1.0
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
1.2K
decreased by-28.66%
Maintainers
3
Weekly downloads
 
Created
Source

Cabin Beta

Cabin is a CLI tool that scaffolds out a Grunt powered static site generator.

Getting Started

First install cabin globally with the following command:

npm install -g cabin

You can then scaffold a static generator with the following command:

cabin new <destination folder> [user/repo]

The first parameter is the name of the destination folder, and the second is the GitHub username and repository name of a theme to use for the site. If the theme parameter is left blank, the default theme will be used.

After scaffolding a site generator, you can run it by entering the following command in the destination folder:

grunt server

Themes

Cabin themes provide styling and structure for your static site project. They work great out of the box and as starting points for more customized sites.

Avaliable Themes

colinwren/Candy

Slick blogging theme, great for use on personal sites

ChrisWren/icoDoc

Minimalist project documentation theme using icons in the navigation

Creating Themes

Configuration

The only file explicitly required is a cabin.json configuration in the root of the repo. This file describes what CSS preprocessors and template languages that your theme supports as well as the configuration for grunt-pages. We currently support EJS and Jade templates and the Sass and LESS style languages.

Here is an example cabin.json file which states that the project supports Sass, Jade, and has the specified config for the grunt-pages task:

{
  "style": [
    "Sass"
  ],
  "template": [
    "Jade"
  ],
  "gruntPages": {
    "posts": {
      "src": "posts",
      "dest": "dist",
      "layout": "src/layouts/post.jade",
      "url": "blog/posts/:title"
    }
  }
}

Note: the configuration of the cabin.json must have dist as the destination folder and the theme files must match the folder structure described below.

Theme file locations

Layouts

Layout files must be in the src/layouts directory.

Styles

Style files must be in the src/styles directory.

Posts

Markdown posts must be in the posts directory.

The best way to learn about how to develop a theme is by referencing the default theme.

Changelog

0.1.0 - grunt server is now the default task. The Gruntfile template now copys images, vanilla css, and scripts and no longer copies .ico and .htaccess files.

0.0.2 - Use git clone instead of downloading theme zips from GitHub repos.

0.0.1 - Only copy specified file extensions from themes.

0.0.0 - Initial push.

FAQs

Package last updated on 24 Jun 2013

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc