cros_workon: add auto-complete support

I often can't remember the full package name of the src repo I'm working
on since it's inconsistent (some people prefix "chromeos-", some don't).
But I do know that often there is only one package name that matches the
short string that I want.  Instead of requiring people to run:
	$ cros_workon list --all | grep foo
	$ cros_workon-$BOARD start <longer name for foo>
Add that smarts into cros_workon itself.  Now if there isn't an exact
match, we'll just pick the first ebuild that matches what they requested.

TEST=`cros_workon stop vboot` will stop chromeos-base/vboot_reference

Change-Id: I7aac70c6f29180d65c084764080628847594a989
Reviewed-by: Matt Tennant <>
Commit-Queue: Mike Frysinger <>
Tested-by: Mike Frysinger <>
1 file changed