Module: Octokit
Overview
Ruby toolkit for the GitHub API
Constant Summary
-
MAJOR =
Current major release.
4
-
MINOR =
Current minor release.
25
-
PATCH =
Current patch level.
1
-
RATE_LIMITED_ERRORS =
# File 'lib/octokit/error.rb', line 355[Octokit::TooManyRequests, Octokit::AbuseDetected].freeze
-
VERSION =
Full release version.
[MAJOR, MINOR, PATCH].join('.').freeze
Class Attribute Summary
Configurable
- Extended
Class Method Summary
-
.client ⇒ Octokit::Client
API client based on configured options
Configurable
-
.enterprise_admin_client ⇒ Octokit::EnterpriseAdminClient
EnterpriseAdminClient
client based on configured optionsConfigurable
-
.enterprise_management_console_client ⇒ Octokit::EnterpriseManagementConsoleClient
EnterpriseManagementConsoleClient
client based on configured optionsConfigurable
- .method_missing(method_name, *args, &block) private
- .respond_to_missing?(method_name, include_private = false) ⇒ Boolean private
Configurable
- Extended
configure | Set configuration options using a block. |
reset! | Reset configuration options to default values. |
same_options? | Compares client options to a Hash of requested options. |
setup | Alias for Configurable#reset!. |
fetch_client_id_and_secret, options |
Class Method Details
.client ⇒ Octokit::Client
API client based on configured options ::Octokit::Configurable
.enterprise_admin_client ⇒ Octokit::EnterpriseAdminClient
::Octokit::EnterpriseAdminClient
client based on configured options ::Octokit::Configurable
# File 'lib/octokit.rb', line 25
def enterprise_admin_client if defined?(@enterprise_admin_client) && @enterprise_admin_client. ( ) return @enterprise_admin_client end @enterprise_admin_client = Octokit::EnterpriseAdminClient.new( ) end
.enterprise_management_console_client ⇒ Octokit::EnterpriseManagementConsoleClient
::Octokit::EnterpriseManagementConsoleClient
client based on configured options ::Octokit::Configurable
# File 'lib/octokit.rb', line 36
def enterprise_management_console_client if defined?(@enterprise_management_console_client) && @enterprise_management_console_client. ( ) return @enterprise_management_console_client end @enterprise_management_console_client = Octokit::EnterpriseManagementConsoleClient.new( ) end
.method_missing(method_name, *args, &block) (private)
[ GitHub ]# File 'lib/octokit.rb', line 52
def method_missing(method_name, *args, &block) if client.respond_to?(method_name) return client.send(method_name, *args, &block) elsif enterprise_admin_client.respond_to?(method_name) return enterprise_admin_client.send(method_name, *args, &block) elsif enterprise_management_console_client.respond_to?(method_name) return enterprise_management_console_client.send(method_name, *args, &block) end super end
.respond_to_missing?(method_name, include_private = false) ⇒ Boolean
(private)
# File 'lib/octokit.rb', line 46
def respond_to_missing?(method_name, include_private = false) client.respond_to?(method_name, include_private) || enterprise_admin_client.respond_to?(method_name, include_private) || enterprise_management_console_client.respond_to?(method_name, include_private) end