Module: Lightning
- Defined in:
- lib/lightning.rb,
lib/lightning/bolt.rb,
lib/lightning/util.rb,
lib/lightning/config.rb,
lib/lightning/builder.rb,
lib/lightning/version.rb,
lib/lightning/commands.rb,
lib/lightning/function.rb,
lib/lightning/generator.rb,
lib/lightning/completion.rb,
lib/lightning/generators.rb,
lib/lightning/commands/core.rb,
lib/lightning/commands_util.rb,
lib/lightning/completion_map.rb
Defined Under Namespace
Modules: Builder, Commands, CommandsUtil, Generators, Util Classes: Bolt, Completion, CompletionMap, Config, Function, Generator
Constant Summary collapse
- VERSION =
'0.4.1'
Class Attribute Summary collapse
-
.config ⇒ Config
Contains all user configuration.
-
.functions ⇒ Hash
Maps function names to Function objects.
Class Method Summary collapse
-
.bolts ⇒ Hash
Maps bolt names to Bolt objects.
-
.dir ⇒ String
Directory for most of lightning’s files, ~/.lightning.
-
.home ⇒ String
User’s home directory, ~.
Class Attribute Details
.config ⇒ Config
Returns Contains all user configuration.
19 20 21 |
# File 'lib/lightning.rb', line 19 def config @config end |
.functions ⇒ Hash
Returns Maps function names to Function objects.
29 30 31 |
# File 'lib/lightning.rb', line 29 def functions @functions end |
Class Method Details
.bolts ⇒ Hash
Returns Maps bolt names to Bolt objects.
24 25 26 |
# File 'lib/lightning.rb', line 24 def bolts @bolts ||= Hash.new {|h,k| h[k] = Bolt.new(k) } end |
.dir ⇒ String
Returns Directory for most of lightning’s files, ~/.lightning.
34 35 36 37 38 39 40 |
# File 'lib/lightning.rb', line 34 def dir @dir ||= begin require 'fileutils' FileUtils.mkdir_p File.join(home, '.lightning') File.join(home, '.lightning') end end |