drewblessing / gitlab-cli

GitLab Command Line Tool - Interact with your GitLab server via the command line to manage snippets, projects and more.
MIT License
166 stars 20 forks source link

Error "Could not find X command" #50

Open enribd opened 10 years ago

enribd commented 10 years ago

Gitlab version: 5.0.1 (Turnkey appliance) Installed via: "gem install gitlab_cli" command Created config file in home directory.

When I try to run commands like "gitlab project add test_project" or "gitlab groups" I get the error --> "Could not find X command". It's weird that the command "gitlab projects" works fine though. Any ideas what could it be?

I need gitlab-cli tool to code a script which automates the creation of a couple hundreds of projects in gitlab web ui for my job. I've read the docs and I think this tool is awesome but I cannot make it work properly. Please help.

malnick commented 10 years ago

Same here, installed via gem and 'gitlab project add' I get 'command add not found.

malnick commented 10 years ago

I also installed via clone and rake and had the same outcome.

TheConnMan commented 10 years ago

Clone and rake just worked for me on Ubuntu 14.04 for anyone in the future who runs into this problem.

34r7h commented 9 years ago

OSX 11,

$ gitlab project help add Could not find command "add".

myoung34 commented 9 years ago

I think the gem is failing to put it in PATH. In cygwin (ruby is native, not via RVM, etc) here's what I did:

Marc-win8:gitlab-cli $ gitlab --version
-bash: gitlab: command not found
Marc-win8:gitlab-cli $ find ~ -name 'gitlab'
/c/Users/myoung/.gem/ruby/gems/gitlab-3.4.0/bin/gitlab
/c/Users/myoung/.gem/ruby/gems/gitlab-3.4.0/lib/gitlab
/c/Users/myoung/.gem/ruby/gems/gitlab-3.4.0/spec/gitlab
Marc-win8:gitlab-cli $ /c/Users/myoung/.gem/ruby/gems/gitlab-3.4.0/bin/gitlab --version
Gitlab Ruby Gem 3.4.0
Marc-win8:gitlab-cli $ ln -s /c/Users/myoung/.gem/ruby/gems/gitlab-3.4.0/bin/gitlab /usr/bin/gitlab
Marc-win8:gitlab-cli $ gitlab --version
Gitlab Ruby Gem 3.4.0

OS X, etc would be similar. To make this a permanent fix you'd want to put something in your ~/.bash_profile file, although I would not recommend linking to that version gem. If you update your gem, then you woulnd't be using the updated version.

Perhaps a real fix should be made, but this might at least get you guys started.

WeiTang114 commented 9 years ago

Same here gitlab project add .. says "Could not find comand "add"." on Ubuntu 14.04, installed with gem, version 2.0.0