starch 1.0.0 → 1.1.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: c170d06a472a33880620fe55dbda11895d058cb2
4
- data.tar.gz: e28d81bc0d32a6d945648b22a906e4e8cc236b3c
3
+ metadata.gz: 4dbb26c89145297f806dbaf3f01e60d896669802
4
+ data.tar.gz: 39d72079f264416902ad25d1906a2265c95cd3e6
5
5
  SHA512:
6
- metadata.gz: 41b9b3c242a16301d1476e16d5770aaa263d19f642895f814de8e4488c02188dbcd7a1b0139499b5d01219d6716957bcd7e4b9e3b7a348a6a31aaaa3b09cf7a5
7
- data.tar.gz: 04bd45f2f50b61569abe2ac6c8d1de19bb977c06e4ee30dcd5f02865afc74e18ef8a8f894783d271b7c2bd30c3eff7553e2746d55bb95580133b626bf9fae380
6
+ metadata.gz: 664a17c1641bd6da3285b4a19f339a4ea2fde063ab299f16a4211ad1607dfac3c040f78bcec6b6dc697b251495f2c41526925d556433742cdaa0eec36aba722c
7
+ data.tar.gz: 05eab8ee19f3354c4c0155a14247d65e3800403b33f2dc09323480c6430305d6f15068e21a958ed01087b66969811caeeca5a903c750ee9aad89802d23d7c629
data/README.md CHANGED
@@ -1,5 +1,6 @@
1
1
  # Starch
2
2
  [![Gem Version](https://badge.fury.io/rb/starch.svg)](http://badge.fury.io/rb/starch)
3
+ [![Code Climate](https://codeclimate.com/github/brianokeefe/starch.png)](https://codeclimate.com/github/brianokeefe/starch)
3
4
 
4
5
  Starch is an opinionated skeleton generator for basic static site development.
5
6
  It will get you going on new sites quickly by generating the meat and *potatoes*
@@ -8,7 +9,7 @@ of your toolchain. Starch gets you:
8
9
  * A simple directory structure
9
10
  * Barebones `bower.json` and `package.json` files for easily saving bower and
10
11
  npm dependencies
11
- * Templates and partials via Handlebars
12
+ * Templates, partials, and helpers via Handlebars
12
13
  * SASS compilation
13
14
  * JS uglification
14
15
  * Coffeescript compilation
@@ -41,6 +42,7 @@ like this:
41
42
  │   │   ├── js
42
43
  │   │   └── stylesheets
43
44
  │   │   └── main.scss
45
+ │   ├── helpers.js
44
46
  │   ├── pages
45
47
  │   ├── partials
46
48
  │   └── templates
@@ -67,6 +69,8 @@ like this:
67
69
  * You can change the template that a given `.html` file uses by specifying
68
70
  `template: some-template-name` in the file's frontmatter.
69
71
  * Use `{{{body}}}` in your templates where the HTML should be rendered.
72
+ * Any Handlebars helpers can live in `app/helpers.js`. In the exported object,
73
+ each key/value pair should resemble `helperName: function(value) { ... }`.
70
74
  * Javascript and Coffeescript should live in `app/assets/js/`.
71
75
  * Javascript files should have a `.js` extension and Coffeescript files should
72
76
  have a `.coffee` extension.
data/features/new.feature CHANGED
@@ -19,6 +19,7 @@ Feature: scaffolding a site
19
19
  | foo/package.json |
20
20
  | foo/bower.json |
21
21
  | foo/app/assets/stylesheets/main.scss |
22
+ | foo/app/helpers.js |
22
23
  | foo/app/templates/default.hbt |
23
24
  And the file "foo/package.json" should contain:
24
25
  """
@@ -1,3 +1,3 @@
1
1
  module Starch
2
- VERSION = "1.0.0"
2
+ VERSION = "1.1.0"
3
3
  end
data/skel/Gruntfile.js CHANGED
@@ -53,6 +53,7 @@ module.exports = function(grunt) {
53
53
  options: {
54
54
  defaultTemplate: 'default',
55
55
  frontmatterType: 'yaml',
56
+ helpers: require('./app/helpers.js'),
56
57
  partialsGlob: 'app/partials/**/*.hbp',
57
58
  templateExt: 'hbt',
58
59
  templates: 'app/templates'
@@ -122,7 +123,7 @@ module.exports = function(grunt) {
122
123
  options: { livereload: true }
123
124
  },
124
125
  html: {
125
- files: 'app/{pages,partials,templates}/**/*',
126
+ files: ['app/{pages,partials,templates}/**/*', 'app/helpers.js'],
126
127
  tasks: ['generator:staging'],
127
128
  options: { livereload: true }
128
129
  },
@@ -0,0 +1,3 @@
1
+ module.exports = {
2
+ }
3
+
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: starch
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0
4
+ version: 1.1.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Brian O'Keefe
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-07-16 00:00:00.000000000 Z
11
+ date: 2014-07-20 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: thor
@@ -93,6 +93,7 @@ files:
93
93
  - skel/app/assets/images/.empty_directory
94
94
  - skel/app/assets/js/.empty_directory
95
95
  - skel/app/assets/stylesheets/main.scss
96
+ - skel/app/helpers.js
96
97
  - skel/app/pages/.empty_directory
97
98
  - skel/app/partials/.empty_directory
98
99
  - skel/app/templates/default.hbt