TODOs and --help.

master
Luka Vandervelden 2019-06-08 03:04:11 +02:00
parent efde03eb79
commit 69ecadaefd
1 changed files with 11 additions and 8 deletions

View File

@ -313,6 +313,9 @@ class Service
File.delete "#{path}/#{name}.#{@environment.name}.yaml"
end
# TODO:
# - Improve error handling when a string is not a proper reference to a
# service instance.
def self.get_by_id(id)
matches = id.match /[^\/]*/
unless matches
@ -333,14 +336,14 @@ parser = OptionParser.parse! do |parser|
parser.banner = "usage: yunoservice <command> [options]\n" +
"\n" +
"commands:\n" +
" start\n" +
" stop\n" +
" status\n" +
" show\n" +
" add\n" +
" del\n" +
" list\n" +
" list-environments\n" +
" start Starts a stopped or dead service.\n" +
" stop Stops a running service.\n" +
" status Shows the current state of a service.\n" +
" show Describe a service in detail.\n" +
" add Add a service to an environment.\n" +
" del Remove a service from an environment.\n" +
" list Lists registered services.\n" +
" list-environments Lists registered environments.\n" +
"\n" +
"options:\n"