Skip to content
This repository has been archived by the owner on Aug 5, 2020. It is now read-only.

Commit

Permalink
Merge pull request #33 from mobify/windows-fix
Browse files Browse the repository at this point in the history
Windows fix
  • Loading branch information
jansepar committed Jul 16, 2012
2 parents 5f322f7 + 8ee2154 commit 9d6a2bd
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 2 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG
@@ -1,3 +1,5 @@
v0.3.8 - Fixes Windows path issue introduced in v0.3.7

v0.3.7 - Provides 'project_name' template variable when compiling mobify.js v0.3.7 - Provides 'project_name' template variable when compiling mobify.js
- Updates Zepto - Updates Zepto
- Image resizer now reports 'project_name' - Image resizer now reports 'project_name'
Expand Down
2 changes: 1 addition & 1 deletion lib/fetcher.js
Expand Up @@ -17,7 +17,7 @@ Fetcher.prototype = {
* *
*/ */
resolve: function(path, base) { resolve: function(path, base) {
if (path.indexOf('/base/') == 0) path = path.slice(1); if (path.indexOf('/base') == 0) path = path.slice(1);
return Path.resolve(base, path); return Path.resolve(base, path);
}, },


Expand Down
2 changes: 1 addition & 1 deletion package.json
@@ -1,6 +1,6 @@
{ {
"name": "mobify-client", "name": "mobify-client",
"version": "0.3.7", "version": "0.3.8",
"description": "Tools for building and compiling mobify.js adaptations", "description": "Tools for building and compiling mobify.js adaptations",
"author": "Mobify <dev@mobify.com>", "author": "Mobify <dev@mobify.com>",
"dependencies": { "dependencies": {
Expand Down
12 changes: 12 additions & 0 deletions test/fetcher.coffee
@@ -0,0 +1,12 @@
Path = require 'path'
Assert = require 'assert'
Fetcher = require '../lib/fetcher'


module.exports =
'test-resolve': (done) ->
fetcher = new Fetcher()
Assert.equal (fetcher.resolve '/base\\tmpl\\base_root.tmpl'), (Path.resolve 'base\\tmpl\\base_root.tmpl')
Assert.equal (fetcher.resolve '/base/tmpl/base_root.tmpl'), (Path.resolve 'base/tmpl/base_root.tmpl')
Assert.equal (fetcher.resolve '/tmpl/base_root.tmpl'), (Path.resolve '/tmpl/base_root.tmpl')
done()

0 comments on commit 9d6a2bd

Please sign in to comment.