rubygems-runtime 0.0.0.2 → 0.0.0.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib-rubygems-trap/rubygems.rb +39 -0
- metadata +5 -6
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e26c9ba19db55f7a29346332a2f45fd2906fdec42b382a8f06c6003f5aeb7549
|
4
|
+
data.tar.gz: aae755faff6c0348658f63457392e96489d8d05c2cb0e8daef1686a91292870b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 670320383e635a68ea50c727f7c2208c4985a25dd35608a664f61246ceaa2d2c90b16aeee2aa6b86ccaff4d13d7b8abb50acad5833888a4d8e45dd494a8f755e
|
7
|
+
data.tar.gz: cd83435da7f5eeec145cdbca4656777e934fbf79520ac4cd7affcad7b0c24e8ea6428f9b677b4f941fda96839c46209bcf6c19a2a60d9b09777c3f985bc17f0b
|
@@ -0,0 +1,39 @@
|
|
1
|
+
message = String.new
|
2
|
+
|
3
|
+
if STDERR.tty?
|
4
|
+
message << "\e[31m"
|
5
|
+
else
|
6
|
+
message << "ERROR: "
|
7
|
+
end
|
8
|
+
|
9
|
+
message << "An attempt to require Rubygems was made; ‘"
|
10
|
+
|
11
|
+
if STDERR.tty?
|
12
|
+
message << "\e[1m"
|
13
|
+
end
|
14
|
+
|
15
|
+
message << "rubygems/runtime"
|
16
|
+
|
17
|
+
if STDERR.tty?
|
18
|
+
message << "\e[22m"
|
19
|
+
end
|
20
|
+
|
21
|
+
message << "’ prevented it"
|
22
|
+
|
23
|
+
if STDERR.tty?
|
24
|
+
message << "\e[m"
|
25
|
+
end
|
26
|
+
|
27
|
+
STDERR.puts(message)
|
28
|
+
|
29
|
+
random_feature = 'rubygems-' + rand(2 ** 64).to_s(36)
|
30
|
+
|
31
|
+
begin
|
32
|
+
require random_feature
|
33
|
+
rescue LoadError => random_feature_load_error
|
34
|
+
message = random_feature_load_error.message.sub(random_feature, 'rubygems')
|
35
|
+
|
36
|
+
backtrace_locations = caller_locations[1..]
|
37
|
+
|
38
|
+
raise LoadError, message, backtrace_locations, cause: nil
|
39
|
+
end
|
metadata
CHANGED
@@ -1,12 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rubygems-runtime
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.0.
|
4
|
+
version: 0.0.0.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Brightworks Digital
|
8
8
|
bindir: bin
|
9
9
|
cert_chain: []
|
10
|
+
date: 1980-01-02 00:00:00.000000000 Z
|
10
11
|
dependencies:
|
11
12
|
- !ruby/object:Gem::Dependency
|
12
13
|
name: test_bench
|
@@ -45,13 +46,11 @@ executables: []
|
|
45
46
|
extensions: []
|
46
47
|
extra_rdoc_files: []
|
47
48
|
files:
|
48
|
-
- lib/rubygems
|
49
|
-
- lib/rubygems/runtime
|
50
|
-
- lib/rubygems/runtime/gem_extensions
|
51
|
-
- lib/rubygems/runtime/gem_extensions/generated.rb
|
49
|
+
- lib-rubygems-trap/rubygems.rb
|
50
|
+
- lib/rubygems/runtime.rb
|
52
51
|
- lib/rubygems/runtime/gem_extensions.rb
|
52
|
+
- lib/rubygems/runtime/gem_extensions/generated.rb
|
53
53
|
- lib/rubygems/runtime/runtime.rb
|
54
|
-
- lib/rubygems/runtime.rb
|
55
54
|
homepage: http://github.com/ntl/rubygems-runtime
|
56
55
|
licenses:
|
57
56
|
- MIT
|