You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@cordova.apache.org by "Andrew Grieve (JIRA)" <ji...@apache.org> on 2015/01/13 21:47:34 UTC
[jira] [Commented] (CB-8303) Use package.json for version info
rather than VERSION file
[ https://issues.apache.org/jira/browse/CB-8303?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14275914#comment-14275914 ]
Andrew Grieve commented on CB-8303:
-----------------------------------
{code}
$ grep -r VERSION src
src/cordova/platform.js: platformVersion = fs.readFileSync(path.join(libDir, 'VERSION'), 'UTF-8').trim();
src/cordova/platform.js: platformVersion = fs.readFileSync(path.join(libDir, 'CordovaLib', 'VERSION'), 'UTF-8').trim();
src/hooks/HooksRunner.js: execOpts.env.CORDOVA_VERSION = require('../../package').version;
src/plugman/platforms/ios.js: var cordovaVersion = fs.readFileSync(path.join(project_dir, 'CordovaLib', 'VERSION'), 'utf8').trim();
{code}
Note that for installed platforms, we should be using version script (cordova/version) to determine version, and for platforms before installed, using package version and falling back to VERSION file.
> Use package.json for version info rather than VERSION file
> ----------------------------------------------------------
>
> Key: CB-8303
> URL: https://issues.apache.org/jira/browse/CB-8303
> Project: Apache Cordova
> Issue Type: Bug
> Components: CordovaLib
> Reporter: Andrew Grieve
> Assignee: Andrew Grieve
> Priority: Minor
>
> cordova-lib sometimes sniffs platform version:
> https://github.com/apache/cordova-lib/blob/0f5dbafface487c5738f294e47520d8b2381134d/cordova-lib/src/cordova/platform.js#L495
> We should have it prefer package.json so that we can delete VERSION files.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org
For additional commands, e-mail: issues-help@cordova.apache.org