Class: Jira::CLI

Inherits:
Thor
  • Object
show all
Defined in:
lib/jira.rb,
lib/jira/commands/log.rb,
lib/jira/commands/new.rb,
lib/jira/commands/link.rb,
lib/jira/commands/vote.rb,
lib/jira/commands/watch.rb,
lib/jira/commands/assign.rb,
lib/jira/commands/delete.rb,
lib/jira/commands/rename.rb,
lib/jira/commands/sprint.rb,
lib/jira/commands/comment.rb,
lib/jira/commands/install.rb,
lib/jira/commands/tickets.rb,
lib/jira/commands/version.rb,
lib/jira/commands/describe.rb,
lib/jira/commands/transition.rb,
lib/jira/commands/attachments.rb

Instance Method Summary collapse

Instance Method Details

#assign(ticket) ⇒ Object



6
7
8
# File 'lib/jira/commands/assign.rb', line 6

def assign(ticket)
  Command::Assign.new(ticket, options).run
end

#attachments(ticket) ⇒ Object



5
6
7
# File 'lib/jira/commands/attachments.rb', line 5

def attachments(ticket)
  Command::Attachments.new(ticket).run
end

#delete(ticket) ⇒ Object



6
7
8
# File 'lib/jira/commands/delete.rb', line 6

def delete(ticket)
  Command::Delete.new(ticket, options[:force]).run
end

#describe(ticket) ⇒ Object



5
6
7
# File 'lib/jira/commands/describe.rb', line 5

def describe(ticket)
  Command::Describe.new(ticket).run
end

#installObject



5
6
7
# File 'lib/jira/commands/install.rb', line 5

def install
  Command::Install.new.run
end


5
6
7
# File 'lib/jira/commands/link.rb', line 5

def link(ticket)
  Command::Link.new(ticket).run
end

#newObject



12
13
14
# File 'lib/jira/commands/new.rb', line 12

def new
  Command::New.new(options).run
end

#rename(ticket) ⇒ Object



6
7
8
# File 'lib/jira/commands/rename.rb', line 6

def rename(ticket)
  Command::Rename.new(ticket, options).run
end

#sprintObject



5
6
7
# File 'lib/jira/commands/sprint.rb', line 5

def sprint
  Command::Sprint.new.run
end

#tickets(jql = "assignee=#{Jira::Core.username}") ⇒ Object



5
6
7
# File 'lib/jira/commands/tickets.rb', line 5

def tickets(jql="assignee=#{Jira::Core.username}")
  Command::Tickets.new(jql).run
end

#transition(ticket) ⇒ Object



7
8
9
# File 'lib/jira/commands/transition.rb', line 7

def transition(ticket)
  Command::Transition.new(ticket, options).run
end

#versionObject



5
6
7
# File 'lib/jira/commands/version.rb', line 5

def version
  say "jira #{Jira::VERSION}"
end