Skip to content

Commit

Permalink
Fix gemspec
Browse files Browse the repository at this point in the history
  • Loading branch information
feelepxyz committed Mar 2, 2021
1 parent da93a7e commit dd36585
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 38 deletions.
55 changes: 20 additions & 35 deletions bundler/helpers/v1/dependabot-bundler-v1-native-helpers.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -3,41 +3,26 @@
require "find"

Gem::Specification.new do |spec|
common_gemspec =
Bundler.load_gemspec_uncached("../../../common/dependabot-common.gemspec")

spec.name = "dependabot-bundler-v1-native-helpers"
spec.summary = "Ruby (bundler) native helpers for dependabot"
spec.version = common_gemspec.version
spec.description = common_gemspec.description

spec.author = common_gemspec.author
spec.email = common_gemspec.email
spec.homepage = common_gemspec.homepage
spec.license = common_gemspec.license

spec.require_path = "lib"
spec.files = []

spec.required_ruby_version = common_gemspec.required_ruby_version
spec.required_rubygems_version = common_gemspec.required_ruby_version

common_gemspec.development_dependencies.each do |dep|
spec.add_development_dependency dep.name, dep.requirement.to_s
end

next unless File.exist?("../../../.gitignore")

ignores = File.readlines("../../../.gitignore").grep(/\S+/).map(&:chomp)

next unless File.directory?("lib")

prefix = "/" + File.basename(File.expand_path(__dir__)) + "/"
Find.find("lib", "monkey_patches") do |path|
if ignores.any? { |i| File.fnmatch(i, prefix + path, File::FNM_DOTMATCH) }
Find.prune
else
spec.files << path unless File.directory?(path)
end
end
spec.version = "0.0.0"
spec.description = "Automated dependency management for Ruby, JavaScript, "\
"Python, PHP, Elixir, Rust, Java, .NET, Elm and Go"

spec.author = "Dependabot"
spec.email = "support@dependabot.com"
spec.homepage = "https://github.com/dependabot/dependabot-core"
spec.license = "Nonstandard" # License Zero Prosperity Public License

spec.require_paths = %w(lib monkey_patches)

spec.required_ruby_version = ">= 2.5.0"
spec.required_rubygems_version = ">= 2.7.3"

spec.add_development_dependency "byebug", "~> 11.0"
spec.add_development_dependency "rspec", "~> 3.8"
spec.add_development_dependency "rspec-its", "~> 1.2"
spec.add_development_dependency "rubocop", "~> 1.11.0"
spec.add_development_dependency "vcr", "6.0.0"
spec.add_development_dependency "webmock", "~> 3.4"
end
3 changes: 0 additions & 3 deletions bundler/helpers/v1/spec/native_spec_helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,6 @@
require "webmock/rspec"
require "byebug"

$LOAD_PATH.unshift(File.expand_path("../lib/", __dir__))
$LOAD_PATH.unshift(File.expand_path("../monkey_patches/", __dir__))

# Bundler monkey patches
require "definition_ruby_version_patch"
require "definition_bundler_version_patch"
Expand Down

0 comments on commit dd36585

Please sign in to comment.