srushti/goldberg

Better error message for incorrect number of arguments

Closed this issue · 1 comments

The directions very clearly say that the way to add a new project is the following:
RAILS_ENV=production bin/goldberg add [--branch <branch_name>] [--scm <git|svn>]

In my haste, I mistook as on optional. Here is what goldberg says

RAILS_ENV=production bin/goldberg add git://github.com/professor/cmusv.git
There was problem adding the project.

In my opinion, I think there should be an error about missing the field.

RAILS_ENV=production bin/goldberg add git://github.com/professor/cmusv.git CMUSV
Executing /usr/bin/env bash -c "git clone --depth 1 git://github.com/professor/cmusv.git /Users/tsedano/.goldberg/projects/CMUSV/code --branch master"

We now prompt the user for the missing arguments. 1eed860