Module: Sumo
- Defined in:
- lib/sumo.rb,
lib/sumo/version.rb
Overview
This module holds versioning information for the gem.
Defined Under Namespace
Modules: Error Classes: CLI, Client, Collection, Config, Search
Constant Summary collapse
- CONFIG_FILE =
Define global constants.
File.('~/.sumo_creds').freeze
- MAJOR =
2
- MINOR =
0
- PATCH =
1
- RELEASE =
nil
- VERSION =
[MAJOR, MINOR, PATCH, RELEASE].compact.join('.')
- API_VERSION =
1
Class Method Summary collapse
-
.client ⇒ Object
The default client for the gem.
-
.client=(new_client) ⇒ Object
Reset the default client for the gem.
-
.config ⇒ Object
The default config for the gem.
-
.config=(new_config) ⇒ Object
Reset the default config for the gem.
-
.creds ⇒ Object
Define top-level functions.
- .creds=(new_creds) ⇒ Object
-
.search(*args) ⇒ Object
Create a new search.
Class Method Details
.client ⇒ Object
The default client for the gem.
47 48 49 |
# File 'lib/sumo.rb', line 47 def client @client ||= Sumo::Client.new end |
.client=(new_client) ⇒ Object
Reset the default client for the gem.
53 54 55 |
# File 'lib/sumo.rb', line 53 def client=(new_client) @client = new_client end |
.config ⇒ Object
The default config for the gem.
35 36 37 |
# File 'lib/sumo.rb', line 35 def config @config ||= Sumo::Config.new end |
.config=(new_config) ⇒ Object
Reset the default config for the gem.
41 42 43 |
# File 'lib/sumo.rb', line 41 def config=(new_config) @config = new_config end |
.creds ⇒ Object
Define top-level functions.
24 25 26 |
# File 'lib/sumo.rb', line 24 def creds @creds ||= config.load_creds! end |
.creds=(new_creds) ⇒ Object
29 30 31 |
# File 'lib/sumo.rb', line 29 def creds=(new_creds) @creds = new_creds end |