Permalink
Browse files

fixes #3, make views.path relative to server path when not using defa…

…ult server
  • Loading branch information...
1 parent df694b2 commit 5376549919ac8b49da29756481a77da022b45809 @dbashford committed Mar 24, 2013
Showing with 9 additions and 2 deletions.
  1. +8 −1 config.coffee
  2. +1 −1 package.json
View
@@ -1,6 +1,7 @@
"use strict"
fs = require 'fs'
+path = require 'path'
exports.defaults = ->
server:
@@ -61,7 +62,13 @@ exports.validate = (config, validators) ->
config.server.views.html = true
config.server.path = validators.determinePath config.server.path, config.root
- config.server.views.path = validators.determinePath config.server.views.path, config.root
+
+ viewsRelativeTo = if config.server.defaultServer.enabled
+ config.root
+ else
+ path.dirname(config.server.path)
+
+ config.server.views.path = validators.determinePath config.server.views.path, viewsRelativeTo
if config.isServer
View
@@ -1,6 +1,6 @@
{
"name": "mimosa-server",
- "version": "0.7.2",
+ "version": "0.7.3",
"homepage": "http://www.mimosajs.com",
"author": "David Bashford",
"description": "Server module for Mimosa browser development workflow tool",

0 comments on commit 5376549

Please sign in to comment.