lib/github_cli/commands/issues.rb in github_cli-0.4.0 vs lib/github_cli/commands/issues.rb in github_cli-0.4.1
- old
+ new
@@ -20,12 +20,10 @@
labels - String list of comma separated Label names. Example: bug,ui,@high
sort - created, updated, comments, default: created \n
direction - asc, desc, default: desc \n
since - Optional string of a timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ \n
DESC
- method_option :params, :type => :hash, :default => {}, :aliases => '-p',
- :desc => 'Additonal request parameters e.i per_page:100'
def list
Issue.all options[:params], options[:format]
end
desc 'repo <user> <repo>', 'List all issues for a repository'
@@ -45,19 +43,15 @@
labels - String list of comma separated Label names. Example: bug,ui,@high\n
sort - created, updated, comments, default: created\n
direction - asc, desc, default: desc\n
since - Optional string of a timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ\n
DESC
- method_option :params, :type => :hash, :default => {}, :aliases => '-p',
- :desc => 'Additonal request parameters e.i per_page:100'
def repo(user, repo)
Issue.all user, repo, options[:params], options[:format]
end
desc 'get <user> <repo> <id>', 'Get a single issue'
- method_option :params, :type => :hash, :default => {}, :aliases => '-p',
- :desc => 'Additonal request parameters e.i per_page:100'
def get(user, repo, id)
Issue.get user, repo, id, options[:params], options[:format]
end
desc 'create <user> <repo>', 'Create an issue.'
@@ -68,12 +62,10 @@
body - Optional string\n
assignee - Optional string - Login for the user that this issue should be assigned to.\n
milestone - Optional number - Milestone to associate this issue with\n
labels - Optional array of strings - Labels to associate with this issue
DESC
- method_option :params, :type => :hash, :default => {}, :aliases => '-p',
- :desc => 'Additonal request parameters e.i per_page:100'
def create(user, repo)
Issue.create user, repo, options[:params], options[:format]
end
desc 'edit <user> <repo> <id>', 'Edit an issue.'
@@ -85,11 +77,9 @@
assignee - Optional string - Login for the user that this issue should be assigned to.\n
state - Optional string - State of the issue: open or closed.
milestone - Optional number - Milestone to associate this issue with\n
labels - Optional array of strings - Labels to associate with this issue
DESC
- method_option :params, :type => :hash, :default => {}, :aliases => '-p',
- :desc => 'Additonal request parameters e.i per_page:100'
def edit(user, repo, id)
Issue.edit user, repo, id, options[:params], options[:format]
end
end # Issues