8000 Fix config list command by ltm · Pull Request #419 · apache/cordova-cli · GitHub
[go: up one dir, main page]

Skip to content

Fix config list command#419

Merged
raphinesse merged 1 commit intoapache:masterfrom
ltm:fix-config-list
Apr 10, 2019
Merged

Fix config list command#419
raphinesse merged 1 commit intoapache:masterfrom
ltm:fix-config-list

Conversation

@ltm
Copy link
Contributor
@ltm ltm commented Apr 3, 2019

The cordova config list command will be executed for any command with list as an argument, such as cordova plugin list. This PR fixes the if-statement to only apply to cordova config list.

Platforms affected

Motivation and Context

This behavior becomes evident due to #418:

$ npm install -g cordova@latest
$ rm ~/.config/configstore/cordova-config.json
$ cordova plugin list
Current working directory is not a Cordova-based project.
Error: ENOENT: no such file or directory, open '/Users/ltm/.config/configstore/cordova-config.json'

The error is triggered by the config list command which is incorrectly being executed as part of the plugin list command.

Description

Testing

Checklist

  • I've run the tests to see all new and existing tests pass
  • I added automated test coverage as appropriate for this change
  • Commit is prefixed with (platform) if this change only applies to one platform (e.g. (android))
  • If this Pull Request resolves an issue, I linked to the issue in the text above (and used the correct keyword to close issues using keywords)
  • I've updated the documentation if necessary

The condition is currently true for any command with `list` as an
argument, such as `cordova plugin list`.
Copy link
Contributor
@raphinesse raphinesse left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 👍

Thanks for your contribution!

@raphinesse raphinesse merged commit 88cc5d9 into apache:master Apr 10, 2019
@ltm ltm deleted the fix-config-list branch April 10, 2019 21:31
@ety001
Copy link
ety001 commented May 24, 2019

Has this fix code released?

@janpio
Copy link
Member
janpio commented May 24, 2019

Last release was March 20, so no.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants

0