cordova-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Martin Gonzalez Glez <martin.c.glez.g...@gmail.com>
Subject [Nodejs 11.x] config.js returns path for local library escaping all backslashes
Date Mon, 05 May 2014 17:41:57 GMT
Hi all,

Using createmobilespec module for cordova-mobile-spec, I've found a problem
that only is reproduced using Nodejs 11.xx (tested with 11.12, 11.13).

config.js returns the following path:
c:%5CUsers%5CAdministrator%5CDesktop%5CTestWP%5Ccordova-wp8
instead of:
c:\Users\Administrator\Desktop\TestWP\cordova-wp8

The only reason, why I've installed nodejs 11 it's because, cordova-coho
requires that specific version to work (since clean-up), on the mobilespec
workflow it requires cordova-coho to get all repositories (not a
requirement as is, but it's recommended to make it easy and fast).
The problem is happening at this line :
https://git-wip-us.apache.org/repos/asf?p=cordova-lib.git;a=blob;f=cordova-lib/src/cordova/config.js;h=d0c8d9aec0270d88ca80ebfd9798b094d3583cb1;hb=master#l75

At url.parse. This module is behaving and messing the path escaping all
backslashes.

Related issue: https://issues.apache.org/jira/browse/CB-6621

It's possible fix this up just returning the library as is retrieved from
the json file, avoiding the url.parse module.

With global libraries plays nice, but when those libraries paths are
present at projectRoot/.cordova/config.json, it happens this problem.

I have reproduced this issue under Windows 7, 8 environments.

Questions:

The workflow would change for mobilespec, install coho with nodejs 11
present, then uninstall it and install 10.xx and continue creating &
deploying the mobilespec project? or just use git and get all repositories
(plugins, cli, platforms-libs) not using cordova-coho?

Changes on config.js to return just the lib path as is retrieved from the
json file (return json.lib[platform].uri) ?

Give the heads-up to nodejs developers, and wait until they fix this up?

Any thoughts or advice to follow with this?

Thanks in advance.

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message