joosy 1.2.0.alpha.31 → 1.2.0.alpha.32

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: 765b432f5a78849d1a9ec069a58579f137d955f3
4
- data.tar.gz: 80829d0f42371c329ec8431d4804b8d23c764e62
3
+ metadata.gz: 8f367893c5c5aa8cfb194f066fb42b2d3747f17e
4
+ data.tar.gz: 41f4a55dd56425b69ecb198e7356e1f37633a4a9
5
5
  SHA512:
6
- metadata.gz: 49288c19845d79274c745dbb7a852a1ce425c3ced4f8bba73a2cdde6a1d793e4b7e011d8c0179c38ee66556f7e998bc40a69e4784b987867f51162b45ee438ea
7
- data.tar.gz: 68a0a84be6f4ae64ebcb3189dca22a49e8ccfdace6709ac3073926472d578d6ad807345afcf040adaba22625a97269335f4c792e43512bffa60fd66eef6f9715
6
+ metadata.gz: 9f697b0c05d9055afbb945885be304960a24a52232f41b48b48e4b23f71aecc58dc9e125a09e810ea4c5cff78bbdd86622f038ccc1b0960a17eb02936f8f5281
7
+ data.tar.gz: 8c9bf63a0b478d1003cee6a006fbf82f0c1444e1ec078913e6958b17578aa60ab81fc278167d81f396866d69c062c9388b148385bcc4b129a2acb028f830e52f
data/bower.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "joosy",
3
- "version": "1.2.0-alpha.31",
3
+ "version": "1.2.0-alpha.32",
4
4
  "main": "lib/joosy.js",
5
5
  "ignore": [
6
6
  "bin",
data/package.json CHANGED
@@ -4,7 +4,7 @@
4
4
  "keywords": [
5
5
  "joosy"
6
6
  ],
7
- "version": "1.2.0-alpha.31",
7
+ "version": "1.2.0-alpha.32",
8
8
  "author": "Boris Staal <boris@staal.io>",
9
9
  "homepage": "http://joosy.ws/",
10
10
  "repository": {
data/tasks/joosy.coffee CHANGED
@@ -52,12 +52,14 @@ module.exports = (grunt) ->
52
52
  callbacks.success?() if deepness == 0
53
53
 
54
54
  haml:
55
- compile: (file, environment='development') ->
55
+ compile: (file, partials='./', environment='development') ->
56
56
  HAMLC = require 'haml-coffee'
57
57
 
58
58
  HAMLC.compile(grunt.file.read file)(
59
59
  environment: environment
60
60
  config: grunt.config.get('joosy.config') || {}
61
+ partial: (location) ->
62
+ grunt.joosy.haml.compile(partials+'/'+location, environment)
61
63
  )
62
64
 
63
65
  server:
@@ -99,8 +101,8 @@ module.exports = (grunt) ->
99
101
 
100
102
  for path in paths
101
103
  server.use path, (req, res, next) ->
102
- if req.url == '/'
103
- res.end grunt.joosy.haml.compile("source/"+entry.src)
104
+ if req.originalUrl == path
105
+ res.end grunt.joosy.haml.compile("source/"+entry.src, entry.partials)
104
106
  console.log "Served #{path} (#{entry.src})"
105
107
  else
106
108
  next()
@@ -163,5 +165,5 @@ module.exports = (grunt) ->
163
165
 
164
166
  grunt.registerTask 'joosy:haml', ->
165
167
  for _, entry of grunt.joosy.helpers.list(@, 'joosy.haml', @args[0])
166
- grunt.file.write entry.dest, grunt.joosy.haml.compile("source/#{entry.src}", 'production')
168
+ grunt.file.write entry.dest, grunt.joosy.haml.compile("source/#{entry.src}", entry.partials, 'production')
167
169
  grunt.log.ok "Compiled #{entry.dest}"
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: joosy
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.2.0.alpha.31
4
+ version: 1.2.0.alpha.32
5
5
  platform: ruby
6
6
  authors:
7
7
  - Boris Staal