debug_inspector 1.0.0 → 1.1.0rc1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.github/workflows/test.yml +24 -31
- data/debug_inspector.gemspec +14 -5
- data/lib/debug_inspector.rb +11 -2
- data/lib/rubyvm/debug_inspector/version.rb +1 -1
- metadata +18 -10
- data/bin/console +0 -14
- data/bin/setup +0 -8
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: ef88a29fcbc378f0b562ce3eaa4030f2ee469a7dcb7ae9a7ad302c72138776ce
|
4
|
+
data.tar.gz: 83187ca79ccf05318ada9d7445fb516b0ffa0b2a3903d6d4f6d84145715bd681
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 1b3b0d06e1e373056f8e9b44f301a6aef08240d129794ed3aadba08e44eae8bc26c05a2fb4f4f690412289a7d8b5693d5fc0f3ddef7e7c23ce153531d37d3196
|
7
|
+
data.tar.gz: 278a86dd3372026aa15e63d9a6680556bfef96a617bb0b7259eb9481a36c181d229a1e4561e10355b4c5ff4b1f91e70b3bac166e763b112c9b6193adbd837a34
|
data/.github/workflows/test.yml
CHANGED
@@ -34,24 +34,10 @@ jobs:
|
|
34
34
|
|
35
35
|
- uses: actions/checkout@v2
|
36
36
|
|
37
|
-
- name: Determine ruby version name
|
38
|
-
id: ruby_version
|
39
|
-
run: |
|
40
|
-
if [[ $OS == 'windows-latest' && $RUBY == '3.0' ]]; then
|
41
|
-
# Windows doesn't have 3.0, so run head there but nowhere else.
|
42
|
-
echo "::set-output name=release::head"
|
43
|
-
else
|
44
|
-
echo "::set-output name=release::$RUBY"
|
45
|
-
fi
|
46
|
-
shell: bash
|
47
|
-
env:
|
48
|
-
OS: ${{ matrix.os }}
|
49
|
-
RUBY: ${{ matrix.ruby }}
|
50
|
-
|
51
37
|
- name: Set up Ruby
|
52
38
|
uses: ruby/setup-ruby@v1
|
53
39
|
with:
|
54
|
-
ruby-version: ${{
|
40
|
+
ruby-version: ${{ matrix.ruby }}
|
55
41
|
bundler-cache: true
|
56
42
|
|
57
43
|
- name: Test
|
@@ -68,6 +54,8 @@ jobs:
|
|
68
54
|
- ubuntu-latest
|
69
55
|
- windows-latest
|
70
56
|
ruby:
|
57
|
+
# This includes rubies that are not actually extended by this gem.
|
58
|
+
# We want to make sure the gem silently fails to load on those platforms.
|
71
59
|
- "2"
|
72
60
|
- "3.0"
|
73
61
|
- "jruby"
|
@@ -81,28 +69,17 @@ jobs:
|
|
81
69
|
|
82
70
|
- uses: actions/checkout@v2
|
83
71
|
|
84
|
-
- name: Determine ruby version name
|
85
|
-
id: ruby_version
|
86
|
-
run: |
|
87
|
-
if [[ $OS == 'windows-latest' && $RUBY == '3.0' ]]; then
|
88
|
-
# Windows doesn't have 3.0, so run head there but nowhere else.
|
89
|
-
echo "::set-output name=release::head"
|
90
|
-
else
|
91
|
-
echo "::set-output name=release::$RUBY"
|
92
|
-
fi
|
93
|
-
shell: bash
|
94
|
-
env:
|
95
|
-
OS: ${{ matrix.os }}
|
96
|
-
RUBY: ${{ matrix.ruby }}
|
97
|
-
|
98
72
|
- name: Set up Ruby
|
99
73
|
uses: ruby/setup-ruby@v1
|
100
74
|
with:
|
101
|
-
ruby-version: ${{
|
75
|
+
ruby-version: ${{ matrix.ruby }}
|
102
76
|
bundler-cache: true
|
103
77
|
|
78
|
+
- name: Build gem
|
79
|
+
run: bundle exec gem build --verbose debug_inspector.gemspec
|
80
|
+
|
104
81
|
- name: Install gem
|
105
|
-
run:
|
82
|
+
run: gem install --verbose debug_inspector*.gem
|
106
83
|
|
107
84
|
- name: Create directory for gem test
|
108
85
|
run: mkdir -p tmp/gem-test
|
@@ -111,9 +88,25 @@ jobs:
|
|
111
88
|
run: echo "gem 'debug_inspector'" > Gemfile
|
112
89
|
working-directory: ./tmp/gem-test
|
113
90
|
|
91
|
+
- name: Get gem installation path
|
92
|
+
id: gem_path
|
93
|
+
run: |
|
94
|
+
gem_path=$(bundle show debug_inspector)
|
95
|
+
echo "gem_path is ${gem_path}"
|
96
|
+
echo "::set-output name=path::${gem_path}"
|
97
|
+
shell: bash
|
98
|
+
working-directory: ./tmp/gem-test
|
99
|
+
|
100
|
+
- name: List installed gem contents
|
101
|
+
run: find .
|
102
|
+
shell: bash
|
103
|
+
working-directory: ${{ steps.gem_path.outputs.path }}
|
104
|
+
|
114
105
|
- name: Test gem load
|
115
106
|
run: bundle exec ruby -e "require 'debug_inspector'"
|
107
|
+
working-directory: ./tmp/gem-test
|
116
108
|
|
117
109
|
- name: Test gem functionality
|
118
110
|
if: ${{ matrix.ruby != 'jruby' && matrix.ruby != 'truffleruby' }}
|
119
111
|
run: bundle exec ruby -e "require 'debug_inspector'; RubyVM::DebugInspector.open { |dc| dc.frame_binding(1) }"
|
112
|
+
working-directory: ./tmp/gem-test
|
data/debug_inspector.gemspec
CHANGED
@@ -2,22 +2,31 @@
|
|
2
2
|
|
3
3
|
Gem::Specification.new do |spec|
|
4
4
|
spec.name = "debug_inspector"
|
5
|
-
spec.version = "1.
|
5
|
+
spec.version = "1.1.0rc1"
|
6
6
|
spec.authors = ["John Mair (banisterfiend)"]
|
7
7
|
spec.email = ["jrmair@gmail.com"]
|
8
8
|
|
9
9
|
spec.summary = %q{A Ruby wrapper for the MRI 2.0 debug_inspector API}
|
10
|
-
spec.description =
|
10
|
+
spec.description = <<-TXT
|
11
|
+
Adds methods to RubyVM::DebugInspector to allow for inspection of backtrace frames.
|
12
|
+
|
13
|
+
The debug_inspector C extension and API were designed and built by Koichi Sasada, this project is just a gemification of his work.
|
14
|
+
|
15
|
+
This library makes use of the debug inspector API which was added to MRI 2.0.0.
|
16
|
+
Only works on MRI 2 and 3. Requiring it on unsupported Rubies will result in a no-op.
|
17
|
+
|
18
|
+
Recommended for use only in debugging situations. Do not use this in production apps.
|
19
|
+
TXT
|
11
20
|
spec.homepage = "https://github.com/banister/debug_inspector"
|
12
21
|
spec.license = "MIT"
|
13
22
|
spec.required_ruby_version = Gem::Requirement.new(">= 2.0")
|
14
23
|
|
15
24
|
spec.metadata["homepage_uri"] = spec.homepage
|
16
|
-
|
17
|
-
|
25
|
+
spec.metadata["source_code_uri"] = "https://github.com/banister/debug_inspector"
|
26
|
+
spec.metadata["changelog_uri"] = "https://github.com/banister/debug_inspector/releases"
|
18
27
|
|
19
28
|
spec.files = Dir.chdir(File.expand_path('..', __FILE__)) do
|
20
|
-
`git ls-files -z`.split("\x0").reject { |f| f.match(%r{^test/}) }
|
29
|
+
`git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|bin)/}) }
|
21
30
|
end
|
22
31
|
|
23
32
|
spec.require_paths = ["lib"]
|
data/lib/debug_inspector.rb
CHANGED
@@ -1,8 +1,17 @@
|
|
1
1
|
require 'rbconfig'
|
2
2
|
dlext = RbConfig::CONFIG['DLEXT']
|
3
3
|
begin
|
4
|
-
|
5
|
-
|
4
|
+
# If the installation task did its job, the extension is in lib/ next to this file.
|
5
|
+
require "debug_inspector.#{dlext}"
|
6
|
+
# We only want to define constants if the extension has loaded.
|
6
7
|
require_relative "rubyvm/debug_inspector/version"
|
7
8
|
rescue LoadError
|
9
|
+
begin
|
10
|
+
# If not, maybe the extension is in ext/
|
11
|
+
require_relative "../ext/debug_inspector/debug_inspector.#{dlext}"
|
12
|
+
# We only want to define constants if the extension has loaded.
|
13
|
+
require_relative "rubyvm/debug_inspector/version"
|
14
|
+
rescue LoadError => e
|
15
|
+
puts "debug_inspector extension was not loaded"
|
16
|
+
end
|
8
17
|
end
|
metadata
CHANGED
@@ -1,16 +1,24 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: debug_inspector
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.1.0rc1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- John Mair (banisterfiend)
|
8
|
-
autorequire:
|
8
|
+
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2021-03-17 00:00:00.000000000 Z
|
12
12
|
dependencies: []
|
13
|
-
description:
|
13
|
+
description: |
|
14
|
+
Adds methods to RubyVM::DebugInspector to allow for inspection of backtrace frames.
|
15
|
+
|
16
|
+
The debug_inspector C extension and API were designed and built by Koichi Sasada, this project is just a gemification of his work.
|
17
|
+
|
18
|
+
This library makes use of the debug inspector API which was added to MRI 2.0.0.
|
19
|
+
Only works on MRI 2 and 3. Requiring it on unsupported Rubies will result in a no-op.
|
20
|
+
|
21
|
+
Recommended for use only in debugging situations. Do not use this in production apps.
|
14
22
|
email:
|
15
23
|
- jrmair@gmail.com
|
16
24
|
executables: []
|
@@ -23,8 +31,6 @@ files:
|
|
23
31
|
- Gemfile
|
24
32
|
- README.md
|
25
33
|
- Rakefile
|
26
|
-
- bin/console
|
27
|
-
- bin/setup
|
28
34
|
- debug_inspector.gemspec
|
29
35
|
- ext/debug_inspector/debug_inspector.c
|
30
36
|
- ext/debug_inspector/extconf.rb
|
@@ -35,7 +41,9 @@ licenses:
|
|
35
41
|
- MIT
|
36
42
|
metadata:
|
37
43
|
homepage_uri: https://github.com/banister/debug_inspector
|
38
|
-
|
44
|
+
source_code_uri: https://github.com/banister/debug_inspector
|
45
|
+
changelog_uri: https://github.com/banister/debug_inspector/releases
|
46
|
+
post_install_message:
|
39
47
|
rdoc_options: []
|
40
48
|
require_paths:
|
41
49
|
- lib
|
@@ -46,12 +54,12 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
46
54
|
version: '2.0'
|
47
55
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
48
56
|
requirements:
|
49
|
-
- - "
|
57
|
+
- - ">"
|
50
58
|
- !ruby/object:Gem::Version
|
51
|
-
version:
|
59
|
+
version: 1.3.1
|
52
60
|
requirements: []
|
53
61
|
rubygems_version: 3.1.4
|
54
|
-
signing_key:
|
62
|
+
signing_key:
|
55
63
|
specification_version: 4
|
56
64
|
summary: A Ruby wrapper for the MRI 2.0 debug_inspector API
|
57
65
|
test_files: []
|
data/bin/console
DELETED
@@ -1,14 +0,0 @@
|
|
1
|
-
#!/usr/bin/env ruby
|
2
|
-
|
3
|
-
require "bundler/setup"
|
4
|
-
require "debug_inspector"
|
5
|
-
|
6
|
-
# You can add fixtures and/or initialization code here to make experimenting
|
7
|
-
# with your gem easier. You can also use a different console, if you like.
|
8
|
-
|
9
|
-
# (If you use this, don't forget to add pry to your Gemfile!)
|
10
|
-
# require "pry"
|
11
|
-
# Pry.start
|
12
|
-
|
13
|
-
require "irb"
|
14
|
-
IRB.start(__FILE__)
|