Module: Danger

Defined in:
lib/danger/ci_source/surf.rb,
lib/danger.rb,
lib/danger/version.rb,
lib/danger/commands/init.rb,
lib/danger/commands/local.rb,
lib/danger/ci_source/drone.rb,
lib/danger/commands/runner.rb,
lib/danger/ci_source/circle.rb,
lib/danger/ci_source/travis.rb,
lib/danger/ci_source/jenkins.rb,
lib/danger/ci_source/teamcity.rb,
lib/danger/core_ext/file_list.rb,
lib/danger/ci_source/buildkite.rb,
lib/danger/ci_source/ci_source.rb,
lib/danger/ci_source/semaphore.rb,
lib/danger/scm_source/git_repo.rb,
lib/danger/ci_source/circle_api.rb,
lib/danger/danger_core/executor.rb,
lib/danger/danger_core/violation.rb,
lib/danger/plugin_support/plugin.rb,
lib/danger/request_source/github.rb,
lib/danger/ci_source/xcode_server.rb,
lib/danger/danger_core/dangerfile.rb,
lib/danger/ci_source/local_git_repo.rb,
lib/danger/danger_core/dangerfile_dsl.rb,
lib/danger/danger_core/standard_error.rb,
lib/danger/commands/plugins/plugin_json.rb,
lib/danger/commands/plugins/plugin_lint.rb,
lib/danger/plugin_support/plugin_linter.rb,
lib/danger/plugin_support/plugin_parser.rb,
lib/danger/request_source/request_source.rb,
lib/danger/commands/plugins/plugin_readme.rb,
lib/danger/danger_core/environment_manager.rb,
lib/danger/commands/init_helpers/interviewer.rb,
lib/danger/commands/local_helpers/http_cache.rb,
lib/danger/plugin_support/plugin_file_resolver.rb,
lib/danger/danger_core/plugins/dangerfile_git_plugin.rb,
lib/danger/danger_core/plugins/dangerfile_github_plugin.rb,
lib/danger/danger_core/plugins/dangerfile_import_plugin.rb,
lib/danger/danger_core/plugins/dangerfile_messaging_plugin.rb

Overview

Danger

Defined Under Namespace

Modules: CISource, RequestSources Classes: CircleAPI, DSLError, Dangerfile, DangerfileGitHubPlugin, DangerfileGitPlugin, DangerfileImportPlugin, DangerfileMessagingPlugin, EnvironmentManager, Executor, FileList, GitRepo, HTTPCache, Init, Interviewer, Local, Plugin, PluginFileResolver, PluginJSON, PluginLint, PluginLinter, PluginParser, PluginReadme, Runner, Violation

Constant Summary collapse

VERSION =
"2.0.0".freeze
DESCRIPTION =
"Automate your PR etiquette.".freeze

Class Method Summary collapse

Class Method Details

.gem_pathString

Returns The path to the local gem directory.

Returns:

  • (String)

    The path to the local gem directory



22
23
24
25
26
27
28
# File 'lib/danger.rb', line 22

def self.gem_path
  gem_name = "danger"
  unless Gem::Specification.find_all_by_name(gem_name).any?
    raise "Couldn't find gem directory for 'danger'"
  end
  return Gem::Specification.find_by_name(gem_name).gem_dir
end