Module: Scriptster
- Defined in:
- lib/scriptster.rb,
lib/scriptster/logger.rb,
lib/scriptster/version.rb,
lib/scriptster/shellcmd.rb,
lib/scriptster/configuration.rb
Overview
The public interface of scriptster is simple. It consists of two functions, cmd and log. The module can be used directly or included in your class.
Defined Under Namespace
Modules: ColourThemes, Logger Classes: Configuration, ShellCmd
Constant Summary collapse
- VERSION =
The version of this library
"0.2.1"
Class Method Summary collapse
-
.cmd(*args) ⇒ Object
Execute a shell command.
-
.configure {|c| ... } ⇒ Object
Use this method to reconfigure the library.
-
.log(*args) ⇒ Object
Pass a message to the logger.
Instance Method Summary collapse
-
#cmd(*args) ⇒ Object
The same as Scriptster.cmd.
-
#log(*args) ⇒ Object
The same as Scriptster.log.
Class Method Details
.cmd(*args) ⇒ Object
Execute a shell command
49 50 51 |
# File 'lib/scriptster.rb', line 49 def self.cmd(*args) ShellCmd.new *args end |
.configure {|c| ... } ⇒ Object
Use this method to reconfigure the library.
71 72 73 74 75 |
# File 'lib/scriptster.rb', line 71 def self.configure c = Configuration.new yield c c.apply end |