Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

'gh' is not a registered wp command #9

Closed
adamwalter opened this issue Dec 13, 2016 · 9 comments
Closed

'gh' is not a registered wp command #9

adamwalter opened this issue Dec 13, 2016 · 9 comments

Comments

@adamwalter
Copy link

I tried installing this package via wp package install using both the package name and the Git URL to this repo, but it is not working.

$ wp package install boonebgorges/wp-cli-git-helper
Installing package boonebgorges/wp-cli-git-helper (dev-master)
Updating /Users/adam/.wp-cli/packages/composer.json to require the package...
Using Composer to install the package...
---
Loading composer repositories with package information
Updating dependencies
$ wp gh
Error: 'gh' is not a registered wp command. See 'wp help'.

I've tried new bash sessions and different WP sites, to no avail. I am seeing the package in my composer.json under both require and repositories, but I do not see the package in my vendors directory.

Any idea what's up?

@boonebgorges
Copy link
Owner

Hey @adamwalter - Sorry for the troubles. The Composer requirements work weirdly in this command because of some dependencies I'm trying (unsuccessfully, it seems) to build between different wp-cli commands. For the time being, you should be able to work around it by putting the following into your ~/.wp-cli/config.yml file:

require:
  - /yourhomedir/.wp-cli/commands/vendor/boonebgorges/wp-cli-git-helper.php

Sorry for the trouble. I will try to figure this out when I get a chance.

@adamwalter
Copy link
Author

No luck. That file doesn't exist for me after installation. Not really sure what's up. How would one go about installing this without using wp package install?

@boonebgorges
Copy link
Owner

Does "that file" mean ~/.wp-cli/config.yml? If it doesn't exist, then create it.

@adamwalter
Copy link
Author

No, .wp-cli/commands/vendor/boonebgorges/wp-cli-git-helper.php.

screen shot 2017-01-02 at 1 57 11 pm

@boonebgorges
Copy link
Owner

Ah. Clone this repo somewhere - say, ~/.wp-cli/commands/wp-cli-git-helper - and replace the require path with the correct path.

@adamwalter
Copy link
Author

Okay, I've got it in there. However, now WP-CLI returns nothing when I try wp gh or even a core command like wp plugin list. Sorry!

@boonebgorges
Copy link
Owner

boonebgorges commented Jan 2, 2017 via email

@adamwalter
Copy link
Author

adamwalter commented Jan 12, 2017

My apologies. I discovered that I was having an Allowed memory size exhausted error behind the scenes due to my Mac's CLI PHP settings.

Your package is the first one that needed > 128M of memory to install, so I had never had a problem installing packages before. This led me to direct my focus on the package and not my system. Thanks for the help regardless!

@boonebgorges
Copy link
Owner

Glad it's working!

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

No branches or pull requests

2 participants