persistent-dmnd 1.0.2 → 1.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 +5 -13
- data/.gitlab-ci.yml +335 -0
- data/README.adoc +4 -1
- data/bin/bundle +105 -0
- data/bin/pry +12 -4
- data/bin/rspec +12 -4
- data/gems.rb +9 -0
- data/lib/persistent_dmnd/version.rb +1 -1
- data/persistent-dmnd.gemspec +4 -3
- metadata +35 -35
- data/.travis.yml +0 -24
- data/Gemfile +0 -1
checksums.yaml
CHANGED
@@ -1,15 +1,7 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
|
5
|
-
data.tar.gz: !binary |-
|
6
|
-
YjE0OWVlYTkyZDg5ZDg2MTk2OGE5ODNlYzVjODIwMTk3NDE2OWE0NQ==
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: 901ff3baa738412b36cff7a151e934b7b5c14091
|
4
|
+
data.tar.gz: 674139fff9877ff358e133cb94330debad1e1a47
|
7
5
|
SHA512:
|
8
|
-
metadata.gz:
|
9
|
-
|
10
|
-
OThmMDNmNjNiOGY0NzNiNGVmNzU1ZWNkM2Q2NzAyY2Y4YzJmMzM0MjQ3NWE0
|
11
|
-
NThlZjRmNDJjZjliNDgwOGMzYmExOWUzNWRlZTkzMjk4NDUyYTk=
|
12
|
-
data.tar.gz: !binary |-
|
13
|
-
NmU5YzY0NDcxMjlmMzA5OTI4MmI0ZjRlMDk1OTIwN2UzOTQxOWIyYmI1Y2I1
|
14
|
-
MGRhYTYxMzhiNDQ2ODBiZDYxNGVhNTU2NDVmMmI0MGVlOTk3MmIxYmMwMzAz
|
15
|
-
ZDljMGExYzlkOGJjNDRiYjc1YTQxN2NlMzA5YmMwZjY3ZTFiNjY=
|
6
|
+
metadata.gz: 8a39fba1fd8ad6ea0c7f632466e23e2b754220d23c457308179cf79fb42e16bc15b722470259b63203833fbc30ec12bee2e945bae5bce2e3db6964c6866f4efd
|
7
|
+
data.tar.gz: ccb9acd0417fe4c09e5ef9e4e96d863d53d2623342445c32f3834726ec34465f3698388c531e53e6822447c7d4ae433a2bc3af1b3595fdaa4cfafad3695350a8
|
data/.gitlab-ci.yml
ADDED
@@ -0,0 +1,335 @@
|
|
1
|
+
# MRI Ruby version list:
|
2
|
+
# https://hub.docker.com/r/library/ruby/tags/
|
3
|
+
|
4
|
+
testruby_1_9_3:
|
5
|
+
image: "ruby:1.9.3"
|
6
|
+
|
7
|
+
# Cache gems in between builds
|
8
|
+
cache:
|
9
|
+
paths:
|
10
|
+
- vendor/ruby
|
11
|
+
|
12
|
+
before_script:
|
13
|
+
- apt-get update >/dev/null # Add UTF-8 support
|
14
|
+
- apt-get install -y locales >/dev/null # |
|
15
|
+
- echo "en_US UTF-8" > /etc/locale.gen # |
|
16
|
+
- locale-gen en_US.UTF-8 # |
|
17
|
+
- export LANG=en_US.UTF-8 # |
|
18
|
+
- export LANGUAGE=en_US:en # |
|
19
|
+
- export LC_ALL=en_US.UTF-8 # v
|
20
|
+
- ruby -v # Print out ruby version for debugging
|
21
|
+
- gem install bundler --no-ri --no-rdoc # Bundler is not installed with the image
|
22
|
+
- bundle install -j $(nproc) --path vendor # Install dependencies into ./vendor/ruby
|
23
|
+
|
24
|
+
script:
|
25
|
+
- bin/rspec
|
26
|
+
|
27
|
+
testruby_2_0:
|
28
|
+
image: "ruby:2.0"
|
29
|
+
|
30
|
+
# Cache gems in between builds
|
31
|
+
cache:
|
32
|
+
paths:
|
33
|
+
- vendor/ruby
|
34
|
+
|
35
|
+
before_script:
|
36
|
+
- apt-get update >/dev/null # Add UTF-8 support
|
37
|
+
- apt-get install -y locales >/dev/null # |
|
38
|
+
- echo "en_US UTF-8" > /etc/locale.gen # |
|
39
|
+
- locale-gen en_US.UTF-8 # |
|
40
|
+
- export LANG=en_US.UTF-8 # |
|
41
|
+
- export LANGUAGE=en_US:en # |
|
42
|
+
- export LC_ALL=en_US.UTF-8 # v
|
43
|
+
- ruby -v # Print out ruby version for debugging
|
44
|
+
- gem install bundler --no-ri --no-rdoc # Bundler is not installed with the image
|
45
|
+
- bundle install -j $(nproc) --path vendor # Install dependencies into ./vendor/ruby
|
46
|
+
|
47
|
+
script:
|
48
|
+
- bin/rspec
|
49
|
+
|
50
|
+
testruby_2_1:
|
51
|
+
image: "ruby:2.1"
|
52
|
+
|
53
|
+
# Cache gems in between builds
|
54
|
+
cache:
|
55
|
+
paths:
|
56
|
+
- vendor/ruby
|
57
|
+
|
58
|
+
before_script:
|
59
|
+
- apt-get update >/dev/null # Add UTF-8 support
|
60
|
+
- apt-get install -y locales >/dev/null # |
|
61
|
+
- echo "en_US UTF-8" > /etc/locale.gen # |
|
62
|
+
- locale-gen en_US.UTF-8 # |
|
63
|
+
- export LANG=en_US.UTF-8 # |
|
64
|
+
- export LANGUAGE=en_US:en # |
|
65
|
+
- export LC_ALL=en_US.UTF-8 # v
|
66
|
+
- ruby -v # Print out ruby version for debugging
|
67
|
+
- gem install bundler --no-ri --no-rdoc # Bundler is not installed with the image
|
68
|
+
- bundle install -j $(nproc) --path vendor # Install dependencies into ./vendor/ruby
|
69
|
+
|
70
|
+
script:
|
71
|
+
- bin/rspec
|
72
|
+
|
73
|
+
testruby_2_2:
|
74
|
+
image: "ruby:2.2"
|
75
|
+
|
76
|
+
# Cache gems in between builds
|
77
|
+
cache:
|
78
|
+
paths:
|
79
|
+
- vendor/ruby
|
80
|
+
|
81
|
+
before_script:
|
82
|
+
- apt-get update >/dev/null # Add UTF-8 support
|
83
|
+
- apt-get install -y locales >/dev/null # |
|
84
|
+
- echo "en_US UTF-8" > /etc/locale.gen # |
|
85
|
+
- locale-gen en_US.UTF-8 # |
|
86
|
+
- export LANG=en_US.UTF-8 # |
|
87
|
+
- export LANGUAGE=en_US:en # |
|
88
|
+
- export LC_ALL=en_US.UTF-8 # v
|
89
|
+
- ruby -v # Print out ruby version for debugging
|
90
|
+
- gem install bundler --no-ri --no-rdoc # Bundler is not installed with the image
|
91
|
+
- bundle install -j $(nproc) --path vendor # Install dependencies into ./vendor/ruby
|
92
|
+
|
93
|
+
script:
|
94
|
+
- bin/rspec
|
95
|
+
|
96
|
+
testruby_2_3:
|
97
|
+
image: "ruby:2.3"
|
98
|
+
|
99
|
+
# Cache gems in between builds
|
100
|
+
cache:
|
101
|
+
paths:
|
102
|
+
- vendor/ruby
|
103
|
+
|
104
|
+
before_script:
|
105
|
+
- apt-get update >/dev/null # Add UTF-8 support
|
106
|
+
- apt-get install -y locales >/dev/null # |
|
107
|
+
- echo "en_US UTF-8" > /etc/locale.gen # |
|
108
|
+
- locale-gen en_US.UTF-8 # |
|
109
|
+
- export LANG=en_US.UTF-8 # |
|
110
|
+
- export LANGUAGE=en_US:en # |
|
111
|
+
- export LC_ALL=en_US.UTF-8 # v
|
112
|
+
- ruby -v # Print out ruby version for debugging
|
113
|
+
- gem install bundler --no-ri --no-rdoc # Bundler is not installed with the image
|
114
|
+
- bundle install -j $(nproc) --path vendor # Install dependencies into ./vendor/ruby
|
115
|
+
|
116
|
+
script:
|
117
|
+
- bin/rspec
|
118
|
+
|
119
|
+
testruby_2_4:
|
120
|
+
image: "ruby:2.4"
|
121
|
+
|
122
|
+
# Cache gems in between builds
|
123
|
+
cache:
|
124
|
+
paths:
|
125
|
+
- vendor/ruby
|
126
|
+
|
127
|
+
before_script:
|
128
|
+
- apt-get update >/dev/null # Add UTF-8 support
|
129
|
+
- apt-get install -y locales >/dev/null # |
|
130
|
+
- echo "en_US UTF-8" > /etc/locale.gen # |
|
131
|
+
- locale-gen en_US.UTF-8 # |
|
132
|
+
- export LANG=en_US.UTF-8 # |
|
133
|
+
- export LANGUAGE=en_US:en # |
|
134
|
+
- export LC_ALL=en_US.UTF-8 # v
|
135
|
+
- ruby -v # Print out ruby version for debugging
|
136
|
+
- gem install bundler --no-ri --no-rdoc # Bundler is not installed with the image
|
137
|
+
- bundle install -j $(nproc) --path vendor # Install dependencies into ./vendor/ruby
|
138
|
+
|
139
|
+
script:
|
140
|
+
- bin/rspec
|
141
|
+
|
142
|
+
testruby_2_5:
|
143
|
+
image: "ruby:2.5"
|
144
|
+
|
145
|
+
# Cache gems in between builds
|
146
|
+
cache:
|
147
|
+
paths:
|
148
|
+
- vendor/ruby
|
149
|
+
|
150
|
+
before_script:
|
151
|
+
- apt-get update >/dev/null # Add UTF-8 support
|
152
|
+
- apt-get install -y locales >/dev/null # |
|
153
|
+
- echo "en_US UTF-8" > /etc/locale.gen # |
|
154
|
+
- locale-gen en_US.UTF-8 # |
|
155
|
+
- export LANG=en_US.UTF-8 # |
|
156
|
+
- export LANGUAGE=en_US:en # |
|
157
|
+
- export LC_ALL=en_US.UTF-8 # v
|
158
|
+
- ruby -v # Print out ruby version for debugging
|
159
|
+
- gem install bundler --no-ri --no-rdoc # Bundler is not installed with the image
|
160
|
+
- bundle install -j $(nproc) --path vendor # Install dependencies into ./vendor/ruby
|
161
|
+
|
162
|
+
script:
|
163
|
+
- bin/rspec
|
164
|
+
|
165
|
+
testruby_2_6:
|
166
|
+
image: "ruby:2.6.0-preview2"
|
167
|
+
|
168
|
+
# Cache gems in between builds
|
169
|
+
cache:
|
170
|
+
paths:
|
171
|
+
- vendor/ruby
|
172
|
+
|
173
|
+
before_script:
|
174
|
+
- apt-get update >/dev/null # Add UTF-8 support
|
175
|
+
- apt-get install -y locales >/dev/null # |
|
176
|
+
- echo "en_US UTF-8" > /etc/locale.gen # |
|
177
|
+
- locale-gen en_US.UTF-8 # |
|
178
|
+
- export LANG=en_US.UTF-8 # |
|
179
|
+
- export LANGUAGE=en_US:en # |
|
180
|
+
- export LC_ALL=en_US.UTF-8 # v
|
181
|
+
- ruby -v # Print out ruby version for debugging
|
182
|
+
- gem install bundler --no-ri --no-rdoc # Bundler is not installed with the image
|
183
|
+
- bundle install -j $(nproc) --path vendor # Install dependencies into ./vendor/ruby
|
184
|
+
|
185
|
+
script:
|
186
|
+
- bin/rspec
|
187
|
+
|
188
|
+
testjruby_1_7:
|
189
|
+
image: "jruby:1.7"
|
190
|
+
|
191
|
+
# Cache gems in between builds
|
192
|
+
cache:
|
193
|
+
paths:
|
194
|
+
- vendor/ruby
|
195
|
+
|
196
|
+
before_script:
|
197
|
+
- apt-get update >/dev/null # Add UTF-8 support
|
198
|
+
- apt-get install -y locales >/dev/null # |
|
199
|
+
- echo "en_US UTF-8" > /etc/locale.gen # |
|
200
|
+
- locale-gen en_US.UTF-8 # |
|
201
|
+
- export LANG=en_US.UTF-8 # |
|
202
|
+
- export LANGUAGE=en_US:en # |
|
203
|
+
- export LC_ALL=en_US.UTF-8 # v
|
204
|
+
- apt-get install -y git >/dev/null # Add git binary
|
205
|
+
- export JRUBY_OPTS=--dev # Faster test runs
|
206
|
+
- ruby -v # Print out ruby version for debugging
|
207
|
+
- gem install bundler --no-ri --no-rdoc # Bundler is not installed with the image
|
208
|
+
- bundle install -j $(nproc) --path vendor # Install dependencies into ./vendor/ruby
|
209
|
+
|
210
|
+
script:
|
211
|
+
- bin/rspec
|
212
|
+
|
213
|
+
testjruby_9_0_1_0:
|
214
|
+
image: "jruby:9.0.1.0"
|
215
|
+
|
216
|
+
# Cache gems in between builds
|
217
|
+
cache:
|
218
|
+
paths:
|
219
|
+
- vendor/ruby
|
220
|
+
|
221
|
+
before_script:
|
222
|
+
- apt-get update >/dev/null # Add UTF-8 support
|
223
|
+
- apt-get install -y locales >/dev/null # |
|
224
|
+
- echo "en_US UTF-8" > /etc/locale.gen # |
|
225
|
+
- locale-gen en_US.UTF-8 # |
|
226
|
+
- export LANG=en_US.UTF-8 # |
|
227
|
+
- export LANGUAGE=en_US:en # |
|
228
|
+
- export LC_ALL=en_US.UTF-8 # v
|
229
|
+
- apt-get install -y git >/dev/null # Add git binary
|
230
|
+
- export JRUBY_OPTS=--dev # Faster test runs
|
231
|
+
- ruby -v # Print out ruby version for debugging
|
232
|
+
- gem install bundler --no-ri --no-rdoc # Bundler is not installed with the image
|
233
|
+
- bundle install -j $(nproc) --path vendor # Install dependencies into ./vendor/ruby
|
234
|
+
|
235
|
+
script:
|
236
|
+
- bin/rspec
|
237
|
+
|
238
|
+
testjruby_9_1:
|
239
|
+
image: "jruby:9.1"
|
240
|
+
|
241
|
+
# Cache gems in between builds
|
242
|
+
cache:
|
243
|
+
paths:
|
244
|
+
- vendor/ruby
|
245
|
+
|
246
|
+
before_script:
|
247
|
+
- apt-get update >/dev/null # Add UTF-8 support
|
248
|
+
- apt-get install -y locales >/dev/null # |
|
249
|
+
- echo "en_US UTF-8" > /etc/locale.gen # |
|
250
|
+
- locale-gen en_US.UTF-8 # |
|
251
|
+
- export LANG=en_US.UTF-8 # |
|
252
|
+
- export LANGUAGE=en_US:en # |
|
253
|
+
- export LC_ALL=en_US.UTF-8 # v
|
254
|
+
- apt-get install -y git >/dev/null # Add git binary
|
255
|
+
- export JRUBY_OPTS=--dev # Faster test runs
|
256
|
+
- ruby -v # Print out ruby version for debugging
|
257
|
+
- gem install bundler --no-ri --no-rdoc # Bundler is not installed with the image
|
258
|
+
- bundle install -j $(nproc) --path vendor # Install dependencies into ./vendor/ruby
|
259
|
+
|
260
|
+
script:
|
261
|
+
- bin/rspec
|
262
|
+
|
263
|
+
# This is not repeated from the 9.2 below! 9.2.0.0 is a very specific version with a bug in the Set interoperability so
|
264
|
+
# we'll want to check that our workaround is working with this one even after the 9.2 branch moves on.
|
265
|
+
testjruby9_2_0_0:
|
266
|
+
image: "jruby:9.2.0.0"
|
267
|
+
|
268
|
+
# Cache gems in between builds
|
269
|
+
cache:
|
270
|
+
paths:
|
271
|
+
- vendor/ruby
|
272
|
+
|
273
|
+
before_script:
|
274
|
+
- apt-get update >/dev/null # Add UTF-8 support
|
275
|
+
- apt-get install -y locales >/dev/null # |
|
276
|
+
- echo "en_US UTF-8" > /etc/locale.gen # |
|
277
|
+
- locale-gen en_US.UTF-8 # |
|
278
|
+
- export LANG=en_US.UTF-8 # |
|
279
|
+
- export LANGUAGE=en_US:en # |
|
280
|
+
- export LC_ALL=en_US.UTF-8 # v
|
281
|
+
- apt-get install -y git >/dev/null # Add git binary
|
282
|
+
- export JRUBY_OPTS=--dev # Faster test runs
|
283
|
+
- ruby -v # Print out ruby version for debugging
|
284
|
+
- gem install bundler --no-ri --no-rdoc # Bundler is not installed with the image
|
285
|
+
- bundle install -j $(nproc) --path vendor # Install dependencies into ./vendor/ruby
|
286
|
+
|
287
|
+
script:
|
288
|
+
- bin/rspec
|
289
|
+
|
290
|
+
testjruby_9_2:
|
291
|
+
image: "jruby:9.2"
|
292
|
+
|
293
|
+
# Cache gems in between builds
|
294
|
+
cache:
|
295
|
+
paths:
|
296
|
+
- vendor/ruby
|
297
|
+
|
298
|
+
before_script:
|
299
|
+
- apt-get update >/dev/null # Add UTF-8 support
|
300
|
+
- apt-get install -y locales >/dev/null # |
|
301
|
+
- echo "en_US UTF-8" > /etc/locale.gen # |
|
302
|
+
- locale-gen en_US.UTF-8 # |
|
303
|
+
- export LANG=en_US.UTF-8 # |
|
304
|
+
- export LANGUAGE=en_US:en # |
|
305
|
+
- export LC_ALL=en_US.UTF-8 # v
|
306
|
+
- apt-get install -y git >/dev/null # Add git binary
|
307
|
+
- export JRUBY_OPTS=--dev # Faster test runs
|
308
|
+
- ruby -v # Print out ruby version for debugging
|
309
|
+
- gem install bundler --no-ri --no-rdoc # Bundler is not installed with the image
|
310
|
+
- bundle install -j $(nproc) --path vendor # Install dependencies into ./vendor/ruby
|
311
|
+
|
312
|
+
script:
|
313
|
+
- bin/rspec
|
314
|
+
|
315
|
+
testtruffleruby:
|
316
|
+
image: "danny02/graalvm"
|
317
|
+
|
318
|
+
before_script:
|
319
|
+
- gu install -c org.graalvm.ruby # Install TruffleRuby
|
320
|
+
- apt-get update >/dev/null # Add UTF-8 support
|
321
|
+
- apt-get install -y locales >/dev/null # |
|
322
|
+
- echo "en_US UTF-8" > /etc/locale.gen # |
|
323
|
+
- locale-gen en_US.UTF-8 # |
|
324
|
+
- export LANG=en_US.UTF-8 # |
|
325
|
+
- export LANGUAGE=en_US:en # |
|
326
|
+
- export LC_ALL=en_US.UTF-8 # v
|
327
|
+
- apt-get install -y git libssl-dev libssl1.1 clang llvm make >/dev/null # Add git binary + truffleruby dependencies
|
328
|
+
- /graalvm*/jre/languages/ruby/lib/truffle/post_install_hook.sh # Rebuild openssl extension, as suggested by install
|
329
|
+
# notes
|
330
|
+
- ruby -v # Print out ruby version for debugging
|
331
|
+
- gem install bundler --no-ri --no-rdoc # Bundler is not installed with the image
|
332
|
+
- bundle install -j $(nproc) # Install dependencies
|
333
|
+
|
334
|
+
script:
|
335
|
+
- bin/rspec
|
data/README.adoc
CHANGED
@@ -97,7 +97,8 @@ It also (_optionally!_) interoperates with the https://github.com/ruby-concurren
|
|
97
97
|
Underneath the covers, persistent-💎 mostly builds atop the awesome https://github.com/hamstergem/hamster[hamster gem].
|
98
98
|
Big thanks to its equally-awesome authors!
|
99
99
|
|
100
|
-
Persistent-💎 is fully supported and tested on Ruby versions 1.9.3 to 2.6.0-preview2,
|
100
|
+
Persistent-💎 is fully supported and tested on Ruby versions 1.9.3 to 2.6.0-preview2, JRuby 1.7 to 9.2, and TruffleRuby 1.0 (latest RC) 🎉.
|
101
|
+
If we don't support your Ruby, it's probably a Python binary instead. Keep calm and 💎 away!
|
101
102
|
|
102
103
|
[discrete]
|
103
104
|
== Contents
|
@@ -372,6 +373,8 @@ When you need to go from thread-safe immutable data structures to thread-safe mu
|
|
372
373
|
|
373
374
|
You'll need to install concurrent-ruby first, see https://github.com/ruby-concurrency/concurrent-ruby#installation for instructions.
|
374
375
|
|
376
|
+
NOTE: If you're using TruffleRuby, you'll need to use concurrent-ruby >= 1.1.0.pre2, as older versions do not work correctly on TruffleRuby.
|
377
|
+
|
375
378
|
After that, you'll be able to:
|
376
379
|
|
377
380
|
==== Array
|
data/bin/bundle
ADDED
@@ -0,0 +1,105 @@
|
|
1
|
+
#!/usr/bin/env ruby
|
2
|
+
# frozen_string_literal: true
|
3
|
+
|
4
|
+
#
|
5
|
+
# This file was generated by Bundler.
|
6
|
+
#
|
7
|
+
# The application 'bundle' is installed as part of a gem, and
|
8
|
+
# this file is here to facilitate running it.
|
9
|
+
#
|
10
|
+
|
11
|
+
require "rubygems"
|
12
|
+
|
13
|
+
m = Module.new do
|
14
|
+
module_function
|
15
|
+
|
16
|
+
def invoked_as_script?
|
17
|
+
File.expand_path($0) == File.expand_path(__FILE__)
|
18
|
+
end
|
19
|
+
|
20
|
+
def env_var_version
|
21
|
+
ENV["BUNDLER_VERSION"]
|
22
|
+
end
|
23
|
+
|
24
|
+
def cli_arg_version
|
25
|
+
return unless invoked_as_script? # don't want to hijack other binstubs
|
26
|
+
return unless "update".start_with?(ARGV.first || " ") # must be running `bundle update`
|
27
|
+
bundler_version = nil
|
28
|
+
update_index = nil
|
29
|
+
ARGV.each_with_index do |a, i|
|
30
|
+
if update_index && update_index.succ == i && a =~ Gem::Version::ANCHORED_VERSION_PATTERN
|
31
|
+
bundler_version = a
|
32
|
+
end
|
33
|
+
next unless a =~ /\A--bundler(?:[= ](#{Gem::Version::VERSION_PATTERN}))?\z/
|
34
|
+
bundler_version = $1 || ">= 0.a"
|
35
|
+
update_index = i
|
36
|
+
end
|
37
|
+
bundler_version
|
38
|
+
end
|
39
|
+
|
40
|
+
def gemfile
|
41
|
+
gemfile = ENV["BUNDLE_GEMFILE"]
|
42
|
+
return gemfile if gemfile && !gemfile.empty?
|
43
|
+
|
44
|
+
File.expand_path("../../gems.rb", __FILE__)
|
45
|
+
end
|
46
|
+
|
47
|
+
def lockfile
|
48
|
+
lockfile =
|
49
|
+
case File.basename(gemfile)
|
50
|
+
when "gems.rb" then gemfile.sub(/\.rb$/, gemfile)
|
51
|
+
else "#{gemfile}.lock"
|
52
|
+
end
|
53
|
+
File.expand_path(lockfile)
|
54
|
+
end
|
55
|
+
|
56
|
+
def lockfile_version
|
57
|
+
return unless File.file?(lockfile)
|
58
|
+
lockfile_contents = File.read(lockfile)
|
59
|
+
return unless lockfile_contents =~ /\n\nBUNDLED WITH\n\s{2,}(#{Gem::Version::VERSION_PATTERN})\n/
|
60
|
+
Regexp.last_match(1)
|
61
|
+
end
|
62
|
+
|
63
|
+
def bundler_version
|
64
|
+
@bundler_version ||= begin
|
65
|
+
env_var_version || cli_arg_version ||
|
66
|
+
lockfile_version || "#{Gem::Requirement.default}.a"
|
67
|
+
end
|
68
|
+
end
|
69
|
+
|
70
|
+
def load_bundler!
|
71
|
+
ENV["BUNDLE_GEMFILE"] ||= gemfile
|
72
|
+
|
73
|
+
# must dup string for RG < 1.8 compatibility
|
74
|
+
activate_bundler(bundler_version.dup)
|
75
|
+
end
|
76
|
+
|
77
|
+
def activate_bundler(bundler_version)
|
78
|
+
if Gem::Version.correct?(bundler_version) && Gem::Version.new(bundler_version).release < Gem::Version.new("2.0")
|
79
|
+
bundler_version = "< 2"
|
80
|
+
end
|
81
|
+
gem_error = activation_error_handling do
|
82
|
+
gem "bundler", bundler_version
|
83
|
+
end
|
84
|
+
return if gem_error.nil?
|
85
|
+
require_error = activation_error_handling do
|
86
|
+
require "bundler/version"
|
87
|
+
end
|
88
|
+
return if require_error.nil? && Gem::Requirement.new(bundler_version).satisfied_by?(Gem::Version.new(Bundler::VERSION))
|
89
|
+
warn "Activating bundler (#{bundler_version}) failed:\n#{gem_error.message}\n\nTo install the version of bundler this project requires, run `gem install bundler -v '#{bundler_version}'`"
|
90
|
+
exit 42
|
91
|
+
end
|
92
|
+
|
93
|
+
def activation_error_handling
|
94
|
+
yield
|
95
|
+
nil
|
96
|
+
rescue StandardError, LoadError => e
|
97
|
+
e
|
98
|
+
end
|
99
|
+
end
|
100
|
+
|
101
|
+
m.load_bundler!
|
102
|
+
|
103
|
+
if m.invoked_as_script?
|
104
|
+
load Gem.bin_path("bundler", "bundle")
|
105
|
+
end
|
data/bin/pry
CHANGED
@@ -8,13 +8,21 @@
|
|
8
8
|
# this file is here to facilitate running it.
|
9
9
|
#
|
10
10
|
|
11
|
-
bundle_binstub = File.expand_path("../bundle", __FILE__)
|
12
|
-
load(bundle_binstub) if File.file?(bundle_binstub)
|
13
|
-
|
14
11
|
require "pathname"
|
15
|
-
ENV["BUNDLE_GEMFILE"] ||= File.expand_path("../../
|
12
|
+
ENV["BUNDLE_GEMFILE"] ||= File.expand_path("../../gems.rb",
|
16
13
|
Pathname.new(__FILE__).realpath)
|
17
14
|
|
15
|
+
bundle_binstub = File.expand_path("../bundle", __FILE__)
|
16
|
+
|
17
|
+
if File.file?(bundle_binstub)
|
18
|
+
if File.read(bundle_binstub, 300) =~ /This file was generated by Bundler/
|
19
|
+
load(bundle_binstub)
|
20
|
+
else
|
21
|
+
abort("Your `bin/bundle` was not generated by Bundler, so this binstub cannot run.
|
22
|
+
Replace `bin/bundle` by running `bundle binstubs bundler --force`, then run this command again.")
|
23
|
+
end
|
24
|
+
end
|
25
|
+
|
18
26
|
require "rubygems"
|
19
27
|
require "bundler/setup"
|
20
28
|
|
data/bin/rspec
CHANGED
@@ -8,13 +8,21 @@
|
|
8
8
|
# this file is here to facilitate running it.
|
9
9
|
#
|
10
10
|
|
11
|
-
bundle_binstub = File.expand_path("../bundle", __FILE__)
|
12
|
-
load(bundle_binstub) if File.file?(bundle_binstub)
|
13
|
-
|
14
11
|
require "pathname"
|
15
|
-
ENV["BUNDLE_GEMFILE"] ||= File.expand_path("../../
|
12
|
+
ENV["BUNDLE_GEMFILE"] ||= File.expand_path("../../gems.rb",
|
16
13
|
Pathname.new(__FILE__).realpath)
|
17
14
|
|
15
|
+
bundle_binstub = File.expand_path("../bundle", __FILE__)
|
16
|
+
|
17
|
+
if File.file?(bundle_binstub)
|
18
|
+
if File.read(bundle_binstub, 300) =~ /This file was generated by Bundler/
|
19
|
+
load(bundle_binstub)
|
20
|
+
else
|
21
|
+
abort("Your `bin/bundle` was not generated by Bundler, so this binstub cannot run.
|
22
|
+
Replace `bin/bundle` by running `bundle binstubs bundler --force`, then run this command again.")
|
23
|
+
end
|
24
|
+
end
|
25
|
+
|
18
26
|
require "rubygems"
|
19
27
|
require "bundler/setup"
|
20
28
|
|
data/gems.rb
CHANGED
@@ -6,3 +6,12 @@ gemspec
|
|
6
6
|
# and JRuby with the same gems.lock
|
7
7
|
# Only used in development
|
8
8
|
gem 'ffi', '~> 1.9.18'
|
9
|
+
|
10
|
+
# As of this writing, the latest available version of concurrent-ruby on
|
11
|
+
# rubygems.org is 1.1.0.pre1, which is broken on TruffleRuby -- at least version
|
12
|
+
# 1.1.0.pre2 is needed to support it.
|
13
|
+
# So for now, let's use the git version of concurrent-ruby in development, so we
|
14
|
+
# can run the full test suite for the gem locally and in CI.
|
15
|
+
if RUBY_ENGINE == 'truffleruby'
|
16
|
+
gem 'concurrent-ruby', git: 'https://github.com/ruby-concurrency/concurrent-ruby'
|
17
|
+
end
|
data/persistent-dmnd.gemspec
CHANGED
@@ -54,11 +54,12 @@ Gem::Specification.new do |spec|
|
|
54
54
|
spec.add_development_dependency 'bundler', '~> 1.16'
|
55
55
|
spec.add_development_dependency 'rake', '~> 12.2'
|
56
56
|
spec.add_development_dependency 'rspec', '~> 3.7'
|
57
|
-
spec.add_development_dependency 'concurrent-ruby', '~> 1.0'
|
57
|
+
spec.add_development_dependency 'concurrent-ruby', '~> 1.0' unless RUBY_ENGINE == 'truffleruby'
|
58
|
+
spec.add_development_dependency 'concurrent-ruby', '~> 1.1' if RUBY_ENGINE == 'truffleruby'
|
58
59
|
spec.add_development_dependency 'rufo', '~> 0.2'
|
59
60
|
spec.add_development_dependency 'pry'
|
60
|
-
spec.add_development_dependency 'pry-byebug'
|
61
|
-
spec.add_development_dependency 'pry-debugger-jruby' if
|
61
|
+
spec.add_development_dependency 'pry-byebug' if RUBY_ENGINE == 'ruby' && !RUBY_VERSION.start_with?('1.9.')
|
62
|
+
spec.add_development_dependency 'pry-debugger-jruby' if RUBY_ENGINE == 'jruby' && !JRUBY_VERSION.start_with?('1.7.')
|
62
63
|
|
63
64
|
spec.add_dependency 'hamster', '~> 3.0'
|
64
65
|
end
|
metadata
CHANGED
@@ -1,111 +1,111 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: persistent-dmnd
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ivo Anjo
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2018-
|
11
|
+
date: 2018-09-16 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
15
|
+
prerelease: false
|
15
16
|
requirement: !ruby/object:Gem::Requirement
|
16
17
|
requirements:
|
17
|
-
- - ~>
|
18
|
+
- - "~>"
|
18
19
|
- !ruby/object:Gem::Version
|
19
20
|
version: '1.16'
|
20
21
|
type: :development
|
21
|
-
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
|
-
- - ~>
|
24
|
+
- - "~>"
|
25
25
|
- !ruby/object:Gem::Version
|
26
26
|
version: '1.16'
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: rake
|
29
|
+
prerelease: false
|
29
30
|
requirement: !ruby/object:Gem::Requirement
|
30
31
|
requirements:
|
31
|
-
- - ~>
|
32
|
+
- - "~>"
|
32
33
|
- !ruby/object:Gem::Version
|
33
34
|
version: '12.2'
|
34
35
|
type: :development
|
35
|
-
prerelease: false
|
36
36
|
version_requirements: !ruby/object:Gem::Requirement
|
37
37
|
requirements:
|
38
|
-
- - ~>
|
38
|
+
- - "~>"
|
39
39
|
- !ruby/object:Gem::Version
|
40
40
|
version: '12.2'
|
41
41
|
- !ruby/object:Gem::Dependency
|
42
42
|
name: rspec
|
43
|
+
prerelease: false
|
43
44
|
requirement: !ruby/object:Gem::Requirement
|
44
45
|
requirements:
|
45
|
-
- - ~>
|
46
|
+
- - "~>"
|
46
47
|
- !ruby/object:Gem::Version
|
47
48
|
version: '3.7'
|
48
49
|
type: :development
|
49
|
-
prerelease: false
|
50
50
|
version_requirements: !ruby/object:Gem::Requirement
|
51
51
|
requirements:
|
52
|
-
- - ~>
|
52
|
+
- - "~>"
|
53
53
|
- !ruby/object:Gem::Version
|
54
54
|
version: '3.7'
|
55
55
|
- !ruby/object:Gem::Dependency
|
56
56
|
name: concurrent-ruby
|
57
|
+
prerelease: false
|
57
58
|
requirement: !ruby/object:Gem::Requirement
|
58
59
|
requirements:
|
59
|
-
- - ~>
|
60
|
+
- - "~>"
|
60
61
|
- !ruby/object:Gem::Version
|
61
|
-
version: '1.
|
62
|
+
version: '1.1'
|
62
63
|
type: :development
|
63
|
-
prerelease: false
|
64
64
|
version_requirements: !ruby/object:Gem::Requirement
|
65
65
|
requirements:
|
66
|
-
- - ~>
|
66
|
+
- - "~>"
|
67
67
|
- !ruby/object:Gem::Version
|
68
|
-
version: '1.
|
68
|
+
version: '1.1'
|
69
69
|
- !ruby/object:Gem::Dependency
|
70
70
|
name: rufo
|
71
|
+
prerelease: false
|
71
72
|
requirement: !ruby/object:Gem::Requirement
|
72
73
|
requirements:
|
73
|
-
- - ~>
|
74
|
+
- - "~>"
|
74
75
|
- !ruby/object:Gem::Version
|
75
76
|
version: '0.2'
|
76
77
|
type: :development
|
77
|
-
prerelease: false
|
78
78
|
version_requirements: !ruby/object:Gem::Requirement
|
79
79
|
requirements:
|
80
|
-
- - ~>
|
80
|
+
- - "~>"
|
81
81
|
- !ruby/object:Gem::Version
|
82
82
|
version: '0.2'
|
83
83
|
- !ruby/object:Gem::Dependency
|
84
84
|
name: pry
|
85
|
+
prerelease: false
|
85
86
|
requirement: !ruby/object:Gem::Requirement
|
86
87
|
requirements:
|
87
|
-
- -
|
88
|
+
- - ">="
|
88
89
|
- !ruby/object:Gem::Version
|
89
90
|
version: '0'
|
90
91
|
type: :development
|
91
|
-
prerelease: false
|
92
92
|
version_requirements: !ruby/object:Gem::Requirement
|
93
93
|
requirements:
|
94
|
-
- -
|
94
|
+
- - ">="
|
95
95
|
- !ruby/object:Gem::Version
|
96
96
|
version: '0'
|
97
97
|
- !ruby/object:Gem::Dependency
|
98
98
|
name: hamster
|
99
|
+
prerelease: false
|
99
100
|
requirement: !ruby/object:Gem::Requirement
|
100
101
|
requirements:
|
101
|
-
- - ~>
|
102
|
+
- - "~>"
|
102
103
|
- !ruby/object:Gem::Version
|
103
104
|
version: '3.0'
|
104
105
|
type: :runtime
|
105
|
-
prerelease: false
|
106
106
|
version_requirements: !ruby/object:Gem::Requirement
|
107
107
|
requirements:
|
108
|
-
- - ~>
|
108
|
+
- - "~>"
|
109
109
|
- !ruby/object:Gem::Version
|
110
110
|
version: '3.0'
|
111
111
|
description: A tiny ruby gem that gives you a beautiful short-hand syntax for creating
|
@@ -115,21 +115,21 @@ executables: []
|
|
115
115
|
extensions: []
|
116
116
|
extra_rdoc_files: []
|
117
117
|
files:
|
118
|
-
- .gitignore
|
119
|
-
- .
|
120
|
-
- .
|
121
|
-
- .
|
118
|
+
- ".gitignore"
|
119
|
+
- ".gitlab-ci.yml"
|
120
|
+
- ".rspec"
|
121
|
+
- ".ruby-version"
|
122
122
|
- CODE_OF_CONDUCT.adoc
|
123
|
-
- Gemfile
|
124
123
|
- LICENSE
|
125
124
|
- README.adoc
|
126
125
|
- Rakefile
|
127
126
|
- UPSTREAM_TODO.adoc
|
127
|
+
- bin/bundle
|
128
128
|
- bin/pry
|
129
129
|
- bin/rspec
|
130
130
|
- gems.rb
|
131
131
|
- lib/persistent-dmnd.rb
|
132
|
-
-
|
132
|
+
- "lib/persistent-\U0001F48E.rb"
|
133
133
|
- lib/persistent_dmnd/array.rb
|
134
134
|
- lib/persistent_dmnd/concurrent_ruby_support.rb
|
135
135
|
- lib/persistent_dmnd/dmndifier.rb
|
@@ -153,18 +153,18 @@ require_paths:
|
|
153
153
|
- lib
|
154
154
|
required_ruby_version: !ruby/object:Gem::Requirement
|
155
155
|
requirements:
|
156
|
-
- -
|
156
|
+
- - ">="
|
157
157
|
- !ruby/object:Gem::Version
|
158
158
|
version: 1.9.3
|
159
159
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
160
160
|
requirements:
|
161
|
-
- -
|
161
|
+
- - ">="
|
162
162
|
- !ruby/object:Gem::Version
|
163
163
|
version: '0'
|
164
164
|
requirements: []
|
165
165
|
rubyforge_project:
|
166
|
-
rubygems_version: 2.6.14
|
166
|
+
rubygems_version: 2.6.14.1
|
167
167
|
signing_key:
|
168
168
|
specification_version: 4
|
169
|
-
summary:
|
169
|
+
summary: "Persistent-\U0001F48E: Because Immutable Data Is Forever"
|
170
170
|
test_files: []
|
data/.travis.yml
DELETED
@@ -1,24 +0,0 @@
|
|
1
|
-
language: ruby
|
2
|
-
sudo: false
|
3
|
-
|
4
|
-
rvm:
|
5
|
-
- jruby-9.1.16.0
|
6
|
-
- 2.5
|
7
|
-
- 2.4
|
8
|
-
- jruby-1.7.9
|
9
|
-
- 1.9.3
|
10
|
-
- 2.3
|
11
|
-
- 2.2
|
12
|
-
- 2.1
|
13
|
-
- 2.0.0
|
14
|
-
- jruby-9.0.0.0
|
15
|
-
- jruby-1.7.27
|
16
|
-
- ruby-2.6.0-preview1
|
17
|
-
- ruby-head
|
18
|
-
- jruby-head
|
19
|
-
|
20
|
-
matrix:
|
21
|
-
allow_failures:
|
22
|
-
- rvm: ruby-head
|
23
|
-
- rvm: jruby-head
|
24
|
-
- rvm: ruby-2.6.0-preview1
|
data/Gemfile
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
./gems.rb
|