Module: Sem4rCli

Defined in:
lib/sem4r_cli/cli_sem.rb,
lib/sem4r_cli/commands/cmd_ads.rb,
lib/sem4r_cli/commands/cmd_job.rb,
lib/sem4r_cli/commands/cmd_info.rb,
lib/sem4r_cli/commands/cmd_ideas.rb,
lib/sem4r_cli/commands/cmd_repdef.rb,
lib/sem4r_cli/commands/cmd_report.rb,
lib/sem4r_cli/commands/cmd_clients.rb,
lib/sem4r_cli/commands/cmd_profile.rb,
lib/sem4r_cli/commands/cmd_campaign.rb,
lib/sem4r_cli/commands/cmd_keywords.rb

Overview


Copyright (c) 2009-2010 Sem4r [email protected]

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

Defined Under Namespace

Classes: CliSem, CommandIdeas, CommandJob, CommandProfile, CommandRepDef, CommandReport

Class Method Summary collapse

Class Method Details

.define_command_sem4r(klass, command_name, description, &block) ⇒ Object

Macro helper for define new sem4r command



30
31
32
33
34
35
36
37
38
39
40
# File 'lib/sem4r_cli/cli_sem.rb', line 30

def self.define_command_sem4r(klass, command_name, description, &block)
  OptParseCommand::define_command(klass, command_name, description) do |cli, options, rest|
     = cli.
    unless 
      puts "please select a valid account!"
      false
    else
      block.call()
    end
  end
end