[
https://issues.apache.org/jira/browse/CB-9157?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15546288#comment-15546288
]
ASF GitHub Bot commented on CB-9157:
------------------------------------
Github user stevengill commented on a diff in the pull request:
https://github.com/apache/cordova-coho/pull/141#discussion_r81827457
--- Diff: src/platform-release.js ---
@@ -59,6 +59,36 @@ function cpAndLog(src, dest) {
}
}
+/*
+ * A function that handles version if it is defined or undefined
+ *
+ * @param {String} repo current repo
+ * @param {String|undefined} ver current version that can be
defined or undefined
+ * @param {String|undefined} validate current version that can be
defined or undefined
+ *
+ * @return {String} version Returns the calculated version
+ *
+ */
+
+function *handleVersion(repo,ver,validate) {
+ var platform = repo.id;
+ var version = ver || undefined;
+
+ if (version === undefined) {
+ yield repoutil.forEachRepo([repo], function*() {
+ // Grabbing version from platformPackageJson
+ var platformPackage = path.join(process.cwd(), 'package.json');
+ var platformPackageJson = require(platformPackage);
+ if(validate === true) {
--- End diff --
This if/else should be tabbed as it is inside the `forEachRepo` block
> coho command to create and copy cordova.js to platform
> -------------------------------------------------------
>
> Key: CB-9157
> URL: https://issues.apache.org/jira/browse/CB-9157
> Project: Apache Cordova
> Issue Type: New Feature
> Components: Coho
> Reporter: Steve Gill
> Assignee: Steve Gill
>
> Right now, prepare-release-branch command does this. I want to split it up
> into its own command so we can update platform's cordova.js files before
> release time.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]