Skip to content

Commit d234d0f

Browse files
committed
Require pry plugins in .pryrc
Pry 0.14.0 dropped support for auto-loading plugins (<https://github.com/pry/pry/blob/master/CHANGELOG.md#breaking-changes>) which is really annyoing. Thus, I've decided to add a project-level `.pryrc` that loads all plugins when one is using pry in dd-trace-rb.
1 parent f7431ce commit d234d0f

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

.pryrc

+4
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
# Modern pry versions don't auto-require plugins, so let's try to load whatever we can
2+
%w[pry-byebug pry-stack_explorer pry-nav pry-debugger-jruby].each do |extension|
3+
begin; require extension; rescue LoadError; nil end
4+
end

ddtrace.gemspec

+1-1
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ Gem::Specification.new do |spec|
3434
.reject { |f| f.match(%r{^(test|spec|features|[.]circleci|[.]github|[.]dd-ci|benchmarks|gemfiles|integration|tasks|sorbet)/}) }
3535
.reject do |f|
3636
['.dockerignore', '.env', '.gitattributes', '.gitlab-ci.yml', '.rspec', '.rubocop.yml',
37-
'.rubocop_todo.yml', '.simplecov', 'Appraisals', 'Gemfile', 'Rakefile', 'docker-compose.yml'].include?(f)
37+
'.rubocop_todo.yml', '.simplecov', 'Appraisals', 'Gemfile', 'Rakefile', 'docker-compose.yml', '.pryrc'].include?(f)
3838
end
3939
spec.executables = ['ddtracerb']
4040
spec.require_paths = ['lib']

0 commit comments

Comments
 (0)