openalias 0.1.0

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 ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: 39ac221aa45bd2163ce9c22a8317021344c4d687
4
+ data.tar.gz: 9fe23da73dcf88520f0e3f5b232220fb729237ad
5
+ SHA512:
6
+ metadata.gz: b729f48f77fc5037d4aed7d41ceed7f987cb508b4ca4d2db54c98a13088421e26c39f2f485093837149dfb91e56707d50e3e4dcfd7c9f9cfe2c0d5e931352ec7
7
+ data.tar.gz: 4ddf3d8e96adbd9969ba880d93e9b266feede39f1c00113ac33dbb377ae537424b66e933488d5929ff9344ed0c7aa8d35a40163b5f1d888000c421459630f5e1
data/.gitignore ADDED
@@ -0,0 +1,15 @@
1
+ /.bundle/
2
+ /.yardoc
3
+ /Gemfile.lock
4
+ /_yardoc/
5
+ /coverage/
6
+ /doc/
7
+ /pkg/
8
+ /spec/reports/
9
+ /tmp/
10
+
11
+ # rspec failure tracking
12
+ .rspec_status
13
+
14
+ /target
15
+ **/*.rs.bk
data/.rspec ADDED
@@ -0,0 +1,2 @@
1
+ --format documentation
2
+ --color
data/.travis.yml ADDED
@@ -0,0 +1,5 @@
1
+ sudo: false
2
+ language: ruby
3
+ rvm:
4
+ - 2.4.1
5
+ before_install: gem install bundler -v 1.15.4
data/Cargo.lock ADDED
@@ -0,0 +1,688 @@
1
+ [[package]]
2
+ name = "advapi32-sys"
3
+ version = "0.2.0"
4
+ source = "registry+https://github.com/rust-lang/crates.io-index"
5
+ dependencies = [
6
+ "winapi 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)",
7
+ "winapi-build 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
8
+ ]
9
+
10
+ [[package]]
11
+ name = "aho-corasick"
12
+ version = "0.6.9"
13
+ source = "registry+https://github.com/rust-lang/crates.io-index"
14
+ dependencies = [
15
+ "memchr 2.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
16
+ ]
17
+
18
+ [[package]]
19
+ name = "ansi_term"
20
+ version = "0.11.0"
21
+ source = "registry+https://github.com/rust-lang/crates.io-index"
22
+ dependencies = [
23
+ "winapi 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)",
24
+ ]
25
+
26
+ [[package]]
27
+ name = "atty"
28
+ version = "0.2.11"
29
+ source = "registry+https://github.com/rust-lang/crates.io-index"
30
+ dependencies = [
31
+ "libc 0.2.43 (registry+https://github.com/rust-lang/crates.io-index)",
32
+ "termion 1.5.1 (registry+https://github.com/rust-lang/crates.io-index)",
33
+ "winapi 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)",
34
+ ]
35
+
36
+ [[package]]
37
+ name = "bitflags"
38
+ version = "0.9.1"
39
+ source = "registry+https://github.com/rust-lang/crates.io-index"
40
+
41
+ [[package]]
42
+ name = "bitflags"
43
+ version = "1.0.4"
44
+ source = "registry+https://github.com/rust-lang/crates.io-index"
45
+
46
+ [[package]]
47
+ name = "build_const"
48
+ version = "0.2.1"
49
+ source = "registry+https://github.com/rust-lang/crates.io-index"
50
+
51
+ [[package]]
52
+ name = "cfg-if"
53
+ version = "0.1.6"
54
+ source = "registry+https://github.com/rust-lang/crates.io-index"
55
+
56
+ [[package]]
57
+ name = "clap"
58
+ version = "2.32.0"
59
+ source = "registry+https://github.com/rust-lang/crates.io-index"
60
+ dependencies = [
61
+ "ansi_term 0.11.0 (registry+https://github.com/rust-lang/crates.io-index)",
62
+ "atty 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)",
63
+ "bitflags 1.0.4 (registry+https://github.com/rust-lang/crates.io-index)",
64
+ "strsim 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)",
65
+ "textwrap 0.10.0 (registry+https://github.com/rust-lang/crates.io-index)",
66
+ "unicode-width 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)",
67
+ "vec_map 0.8.1 (registry+https://github.com/rust-lang/crates.io-index)",
68
+ ]
69
+
70
+ [[package]]
71
+ name = "crc"
72
+ version = "1.8.1"
73
+ source = "registry+https://github.com/rust-lang/crates.io-index"
74
+ dependencies = [
75
+ "build_const 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
76
+ ]
77
+
78
+ [[package]]
79
+ name = "diff"
80
+ version = "0.1.11"
81
+ source = "registry+https://github.com/rust-lang/crates.io-index"
82
+
83
+ [[package]]
84
+ name = "embed-resource"
85
+ version = "1.1.4"
86
+ source = "registry+https://github.com/rust-lang/crates.io-index"
87
+ dependencies = [
88
+ "winreg 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
89
+ ]
90
+
91
+ [[package]]
92
+ name = "env_logger"
93
+ version = "0.4.3"
94
+ source = "registry+https://github.com/rust-lang/crates.io-index"
95
+ dependencies = [
96
+ "log 0.3.9 (registry+https://github.com/rust-lang/crates.io-index)",
97
+ "regex 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)",
98
+ ]
99
+
100
+ [[package]]
101
+ name = "extprim"
102
+ version = "1.6.0"
103
+ source = "registry+https://github.com/rust-lang/crates.io-index"
104
+ dependencies = [
105
+ "num-traits 0.2.6 (registry+https://github.com/rust-lang/crates.io-index)",
106
+ "rand 0.4.3 (registry+https://github.com/rust-lang/crates.io-index)",
107
+ "rustc_version 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)",
108
+ "semver 0.9.0 (registry+https://github.com/rust-lang/crates.io-index)",
109
+ "serde 1.0.80 (registry+https://github.com/rust-lang/crates.io-index)",
110
+ ]
111
+
112
+ [[package]]
113
+ name = "fuchsia-zircon"
114
+ version = "0.3.3"
115
+ source = "registry+https://github.com/rust-lang/crates.io-index"
116
+ dependencies = [
117
+ "bitflags 1.0.4 (registry+https://github.com/rust-lang/crates.io-index)",
118
+ "fuchsia-zircon-sys 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)",
119
+ ]
120
+
121
+ [[package]]
122
+ name = "fuchsia-zircon-sys"
123
+ version = "0.3.3"
124
+ source = "registry+https://github.com/rust-lang/crates.io-index"
125
+
126
+ [[package]]
127
+ name = "getopts"
128
+ version = "0.2.18"
129
+ source = "registry+https://github.com/rust-lang/crates.io-index"
130
+ dependencies = [
131
+ "unicode-width 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)",
132
+ ]
133
+
134
+ [[package]]
135
+ name = "idna"
136
+ version = "0.1.5"
137
+ source = "registry+https://github.com/rust-lang/crates.io-index"
138
+ dependencies = [
139
+ "matches 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)",
140
+ "unicode-bidi 0.3.4 (registry+https://github.com/rust-lang/crates.io-index)",
141
+ "unicode-normalization 0.1.7 (registry+https://github.com/rust-lang/crates.io-index)",
142
+ ]
143
+
144
+ [[package]]
145
+ name = "itoa"
146
+ version = "0.4.3"
147
+ source = "registry+https://github.com/rust-lang/crates.io-index"
148
+
149
+ [[package]]
150
+ name = "kernel32-sys"
151
+ version = "0.2.2"
152
+ source = "registry+https://github.com/rust-lang/crates.io-index"
153
+ dependencies = [
154
+ "winapi 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)",
155
+ "winapi-build 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
156
+ ]
157
+
158
+ [[package]]
159
+ name = "lazy_static"
160
+ version = "0.2.11"
161
+ source = "registry+https://github.com/rust-lang/crates.io-index"
162
+
163
+ [[package]]
164
+ name = "lazy_static"
165
+ version = "1.1.0"
166
+ source = "registry+https://github.com/rust-lang/crates.io-index"
167
+ dependencies = [
168
+ "version_check 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)",
169
+ ]
170
+
171
+ [[package]]
172
+ name = "libc"
173
+ version = "0.2.43"
174
+ source = "registry+https://github.com/rust-lang/crates.io-index"
175
+
176
+ [[package]]
177
+ name = "log"
178
+ version = "0.3.9"
179
+ source = "registry+https://github.com/rust-lang/crates.io-index"
180
+ dependencies = [
181
+ "log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)",
182
+ ]
183
+
184
+ [[package]]
185
+ name = "log"
186
+ version = "0.4.6"
187
+ source = "registry+https://github.com/rust-lang/crates.io-index"
188
+ dependencies = [
189
+ "cfg-if 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)",
190
+ ]
191
+
192
+ [[package]]
193
+ name = "matches"
194
+ version = "0.1.8"
195
+ source = "registry+https://github.com/rust-lang/crates.io-index"
196
+
197
+ [[package]]
198
+ name = "memchr"
199
+ version = "2.1.1"
200
+ source = "registry+https://github.com/rust-lang/crates.io-index"
201
+ dependencies = [
202
+ "cfg-if 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)",
203
+ "libc 0.2.43 (registry+https://github.com/rust-lang/crates.io-index)",
204
+ "version_check 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)",
205
+ ]
206
+
207
+ [[package]]
208
+ name = "num-traits"
209
+ version = "0.2.6"
210
+ source = "registry+https://github.com/rust-lang/crates.io-index"
211
+
212
+ [[package]]
213
+ name = "openalias"
214
+ version = "0.1.0"
215
+ dependencies = [
216
+ "openalias 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
217
+ "ruru 0.9.3 (registry+https://github.com/rust-lang/crates.io-index)",
218
+ ]
219
+
220
+ [[package]]
221
+ name = "openalias"
222
+ version = "0.2.0"
223
+ source = "registry+https://github.com/rust-lang/crates.io-index"
224
+ dependencies = [
225
+ "clap 2.32.0 (registry+https://github.com/rust-lang/crates.io-index)",
226
+ "crc 1.8.1 (registry+https://github.com/rust-lang/crates.io-index)",
227
+ "embed-resource 1.1.4 (registry+https://github.com/rust-lang/crates.io-index)",
228
+ "peg 0.5.7 (registry+https://github.com/rust-lang/crates.io-index)",
229
+ "resolve 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)",
230
+ "rustfmt 0.9.0 (registry+https://github.com/rust-lang/crates.io-index)",
231
+ ]
232
+
233
+ [[package]]
234
+ name = "peg"
235
+ version = "0.5.7"
236
+ source = "registry+https://github.com/rust-lang/crates.io-index"
237
+ dependencies = [
238
+ "quote 0.3.15 (registry+https://github.com/rust-lang/crates.io-index)",
239
+ ]
240
+
241
+ [[package]]
242
+ name = "proc-macro2"
243
+ version = "0.4.20"
244
+ source = "registry+https://github.com/rust-lang/crates.io-index"
245
+ dependencies = [
246
+ "unicode-xid 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
247
+ ]
248
+
249
+ [[package]]
250
+ name = "quote"
251
+ version = "0.3.15"
252
+ source = "registry+https://github.com/rust-lang/crates.io-index"
253
+
254
+ [[package]]
255
+ name = "quote"
256
+ version = "0.6.9"
257
+ source = "registry+https://github.com/rust-lang/crates.io-index"
258
+ dependencies = [
259
+ "proc-macro2 0.4.20 (registry+https://github.com/rust-lang/crates.io-index)",
260
+ ]
261
+
262
+ [[package]]
263
+ name = "rand"
264
+ version = "0.3.22"
265
+ source = "registry+https://github.com/rust-lang/crates.io-index"
266
+ dependencies = [
267
+ "fuchsia-zircon 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)",
268
+ "libc 0.2.43 (registry+https://github.com/rust-lang/crates.io-index)",
269
+ "rand 0.4.3 (registry+https://github.com/rust-lang/crates.io-index)",
270
+ ]
271
+
272
+ [[package]]
273
+ name = "rand"
274
+ version = "0.4.3"
275
+ source = "registry+https://github.com/rust-lang/crates.io-index"
276
+ dependencies = [
277
+ "fuchsia-zircon 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)",
278
+ "libc 0.2.43 (registry+https://github.com/rust-lang/crates.io-index)",
279
+ "winapi 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)",
280
+ ]
281
+
282
+ [[package]]
283
+ name = "redox_syscall"
284
+ version = "0.1.40"
285
+ source = "registry+https://github.com/rust-lang/crates.io-index"
286
+
287
+ [[package]]
288
+ name = "redox_termios"
289
+ version = "0.1.1"
290
+ source = "registry+https://github.com/rust-lang/crates.io-index"
291
+ dependencies = [
292
+ "redox_syscall 0.1.40 (registry+https://github.com/rust-lang/crates.io-index)",
293
+ ]
294
+
295
+ [[package]]
296
+ name = "regex"
297
+ version = "0.2.11"
298
+ source = "registry+https://github.com/rust-lang/crates.io-index"
299
+ dependencies = [
300
+ "aho-corasick 0.6.9 (registry+https://github.com/rust-lang/crates.io-index)",
301
+ "memchr 2.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
302
+ "regex-syntax 0.5.6 (registry+https://github.com/rust-lang/crates.io-index)",
303
+ "thread_local 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)",
304
+ "utf8-ranges 1.0.2 (registry+https://github.com/rust-lang/crates.io-index)",
305
+ ]
306
+
307
+ [[package]]
308
+ name = "regex-syntax"
309
+ version = "0.5.6"
310
+ source = "registry+https://github.com/rust-lang/crates.io-index"
311
+ dependencies = [
312
+ "ucd-util 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)",
313
+ ]
314
+
315
+ [[package]]
316
+ name = "resolve"
317
+ version = "0.1.2"
318
+ source = "registry+https://github.com/rust-lang/crates.io-index"
319
+ dependencies = [
320
+ "idna 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)",
321
+ "libc 0.2.43 (registry+https://github.com/rust-lang/crates.io-index)",
322
+ "log 0.3.9 (registry+https://github.com/rust-lang/crates.io-index)",
323
+ "rand 0.3.22 (registry+https://github.com/rust-lang/crates.io-index)",
324
+ ]
325
+
326
+ [[package]]
327
+ name = "ruby-sys"
328
+ version = "0.2.20"
329
+ source = "registry+https://github.com/rust-lang/crates.io-index"
330
+ dependencies = [
331
+ "libc 0.2.43 (registry+https://github.com/rust-lang/crates.io-index)",
332
+ ]
333
+
334
+ [[package]]
335
+ name = "ruru"
336
+ version = "0.9.3"
337
+ source = "registry+https://github.com/rust-lang/crates.io-index"
338
+ dependencies = [
339
+ "lazy_static 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)",
340
+ "ruby-sys 0.2.20 (registry+https://github.com/rust-lang/crates.io-index)",
341
+ ]
342
+
343
+ [[package]]
344
+ name = "rustc_version"
345
+ version = "0.2.3"
346
+ source = "registry+https://github.com/rust-lang/crates.io-index"
347
+ dependencies = [
348
+ "semver 0.9.0 (registry+https://github.com/rust-lang/crates.io-index)",
349
+ ]
350
+
351
+ [[package]]
352
+ name = "rustfmt"
353
+ version = "0.9.0"
354
+ source = "registry+https://github.com/rust-lang/crates.io-index"
355
+ dependencies = [
356
+ "diff 0.1.11 (registry+https://github.com/rust-lang/crates.io-index)",
357
+ "env_logger 0.4.3 (registry+https://github.com/rust-lang/crates.io-index)",
358
+ "getopts 0.2.18 (registry+https://github.com/rust-lang/crates.io-index)",
359
+ "kernel32-sys 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
360
+ "libc 0.2.43 (registry+https://github.com/rust-lang/crates.io-index)",
361
+ "log 0.3.9 (registry+https://github.com/rust-lang/crates.io-index)",
362
+ "regex 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)",
363
+ "serde 1.0.80 (registry+https://github.com/rust-lang/crates.io-index)",
364
+ "serde_derive 1.0.80 (registry+https://github.com/rust-lang/crates.io-index)",
365
+ "serde_json 1.0.32 (registry+https://github.com/rust-lang/crates.io-index)",
366
+ "strings 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
367
+ "syntex_errors 0.59.1 (registry+https://github.com/rust-lang/crates.io-index)",
368
+ "syntex_syntax 0.59.1 (registry+https://github.com/rust-lang/crates.io-index)",
369
+ "term 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)",
370
+ "toml 0.4.8 (registry+https://github.com/rust-lang/crates.io-index)",
371
+ "unicode-segmentation 1.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
372
+ "winapi 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)",
373
+ ]
374
+
375
+ [[package]]
376
+ name = "ryu"
377
+ version = "0.2.6"
378
+ source = "registry+https://github.com/rust-lang/crates.io-index"
379
+
380
+ [[package]]
381
+ name = "semver"
382
+ version = "0.9.0"
383
+ source = "registry+https://github.com/rust-lang/crates.io-index"
384
+ dependencies = [
385
+ "semver-parser 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)",
386
+ ]
387
+
388
+ [[package]]
389
+ name = "semver-parser"
390
+ version = "0.7.0"
391
+ source = "registry+https://github.com/rust-lang/crates.io-index"
392
+
393
+ [[package]]
394
+ name = "serde"
395
+ version = "1.0.80"
396
+ source = "registry+https://github.com/rust-lang/crates.io-index"
397
+ dependencies = [
398
+ "serde_derive 1.0.80 (registry+https://github.com/rust-lang/crates.io-index)",
399
+ ]
400
+
401
+ [[package]]
402
+ name = "serde_derive"
403
+ version = "1.0.80"
404
+ source = "registry+https://github.com/rust-lang/crates.io-index"
405
+ dependencies = [
406
+ "proc-macro2 0.4.20 (registry+https://github.com/rust-lang/crates.io-index)",
407
+ "quote 0.6.9 (registry+https://github.com/rust-lang/crates.io-index)",
408
+ "syn 0.15.17 (registry+https://github.com/rust-lang/crates.io-index)",
409
+ ]
410
+
411
+ [[package]]
412
+ name = "serde_json"
413
+ version = "1.0.32"
414
+ source = "registry+https://github.com/rust-lang/crates.io-index"
415
+ dependencies = [
416
+ "itoa 0.4.3 (registry+https://github.com/rust-lang/crates.io-index)",
417
+ "ryu 0.2.6 (registry+https://github.com/rust-lang/crates.io-index)",
418
+ "serde 1.0.80 (registry+https://github.com/rust-lang/crates.io-index)",
419
+ ]
420
+
421
+ [[package]]
422
+ name = "strings"
423
+ version = "0.1.1"
424
+ source = "registry+https://github.com/rust-lang/crates.io-index"
425
+ dependencies = [
426
+ "log 0.3.9 (registry+https://github.com/rust-lang/crates.io-index)",
427
+ ]
428
+
429
+ [[package]]
430
+ name = "strsim"
431
+ version = "0.7.0"
432
+ source = "registry+https://github.com/rust-lang/crates.io-index"
433
+
434
+ [[package]]
435
+ name = "syn"
436
+ version = "0.15.17"
437
+ source = "registry+https://github.com/rust-lang/crates.io-index"
438
+ dependencies = [
439
+ "proc-macro2 0.4.20 (registry+https://github.com/rust-lang/crates.io-index)",
440
+ "quote 0.6.9 (registry+https://github.com/rust-lang/crates.io-index)",
441
+ "unicode-xid 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
442
+ ]
443
+
444
+ [[package]]
445
+ name = "syntex_errors"
446
+ version = "0.59.1"
447
+ source = "registry+https://github.com/rust-lang/crates.io-index"
448
+ dependencies = [
449
+ "libc 0.2.43 (registry+https://github.com/rust-lang/crates.io-index)",
450
+ "serde 1.0.80 (registry+https://github.com/rust-lang/crates.io-index)",
451
+ "serde_derive 1.0.80 (registry+https://github.com/rust-lang/crates.io-index)",
452
+ "syntex_pos 0.59.1 (registry+https://github.com/rust-lang/crates.io-index)",
453
+ "term 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)",
454
+ "unicode-xid 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
455
+ ]
456
+
457
+ [[package]]
458
+ name = "syntex_pos"
459
+ version = "0.59.1"
460
+ source = "registry+https://github.com/rust-lang/crates.io-index"
461
+ dependencies = [
462
+ "serde 1.0.80 (registry+https://github.com/rust-lang/crates.io-index)",
463
+ "serde_derive 1.0.80 (registry+https://github.com/rust-lang/crates.io-index)",
464
+ ]
465
+
466
+ [[package]]
467
+ name = "syntex_syntax"
468
+ version = "0.59.1"
469
+ source = "registry+https://github.com/rust-lang/crates.io-index"
470
+ dependencies = [
471
+ "bitflags 0.9.1 (registry+https://github.com/rust-lang/crates.io-index)",
472
+ "extprim 1.6.0 (registry+https://github.com/rust-lang/crates.io-index)",
473
+ "log 0.3.9 (registry+https://github.com/rust-lang/crates.io-index)",
474
+ "serde 1.0.80 (registry+https://github.com/rust-lang/crates.io-index)",
475
+ "serde_derive 1.0.80 (registry+https://github.com/rust-lang/crates.io-index)",
476
+ "serde_json 1.0.32 (registry+https://github.com/rust-lang/crates.io-index)",
477
+ "syntex_errors 0.59.1 (registry+https://github.com/rust-lang/crates.io-index)",
478
+ "syntex_pos 0.59.1 (registry+https://github.com/rust-lang/crates.io-index)",
479
+ "unicode-xid 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
480
+ ]
481
+
482
+ [[package]]
483
+ name = "term"
484
+ version = "0.4.6"
485
+ source = "registry+https://github.com/rust-lang/crates.io-index"
486
+ dependencies = [
487
+ "kernel32-sys 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
488
+ "winapi 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)",
489
+ ]
490
+
491
+ [[package]]
492
+ name = "termion"
493
+ version = "1.5.1"
494
+ source = "registry+https://github.com/rust-lang/crates.io-index"
495
+ dependencies = [
496
+ "libc 0.2.43 (registry+https://github.com/rust-lang/crates.io-index)",
497
+ "redox_syscall 0.1.40 (registry+https://github.com/rust-lang/crates.io-index)",
498
+ "redox_termios 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
499
+ ]
500
+
501
+ [[package]]
502
+ name = "textwrap"
503
+ version = "0.10.0"
504
+ source = "registry+https://github.com/rust-lang/crates.io-index"
505
+ dependencies = [
506
+ "unicode-width 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)",
507
+ ]
508
+
509
+ [[package]]
510
+ name = "thread_local"
511
+ version = "0.3.6"
512
+ source = "registry+https://github.com/rust-lang/crates.io-index"
513
+ dependencies = [
514
+ "lazy_static 1.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
515
+ ]
516
+
517
+ [[package]]
518
+ name = "toml"
519
+ version = "0.4.8"
520
+ source = "registry+https://github.com/rust-lang/crates.io-index"
521
+ dependencies = [
522
+ "serde 1.0.80 (registry+https://github.com/rust-lang/crates.io-index)",
523
+ ]
524
+
525
+ [[package]]
526
+ name = "ucd-util"
527
+ version = "0.1.2"
528
+ source = "registry+https://github.com/rust-lang/crates.io-index"
529
+
530
+ [[package]]
531
+ name = "unicode-bidi"
532
+ version = "0.3.4"
533
+ source = "registry+https://github.com/rust-lang/crates.io-index"
534
+ dependencies = [
535
+ "matches 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)",
536
+ ]
537
+
538
+ [[package]]
539
+ name = "unicode-normalization"
540
+ version = "0.1.7"
541
+ source = "registry+https://github.com/rust-lang/crates.io-index"
542
+
543
+ [[package]]
544
+ name = "unicode-segmentation"
545
+ version = "1.2.1"
546
+ source = "registry+https://github.com/rust-lang/crates.io-index"
547
+
548
+ [[package]]
549
+ name = "unicode-width"
550
+ version = "0.1.5"
551
+ source = "registry+https://github.com/rust-lang/crates.io-index"
552
+
553
+ [[package]]
554
+ name = "unicode-xid"
555
+ version = "0.1.0"
556
+ source = "registry+https://github.com/rust-lang/crates.io-index"
557
+
558
+ [[package]]
559
+ name = "utf8-ranges"
560
+ version = "1.0.2"
561
+ source = "registry+https://github.com/rust-lang/crates.io-index"
562
+
563
+ [[package]]
564
+ name = "vec_map"
565
+ version = "0.8.1"
566
+ source = "registry+https://github.com/rust-lang/crates.io-index"
567
+
568
+ [[package]]
569
+ name = "version_check"
570
+ version = "0.1.5"
571
+ source = "registry+https://github.com/rust-lang/crates.io-index"
572
+
573
+ [[package]]
574
+ name = "winapi"
575
+ version = "0.2.8"
576
+ source = "registry+https://github.com/rust-lang/crates.io-index"
577
+
578
+ [[package]]
579
+ name = "winapi"
580
+ version = "0.3.6"
581
+ source = "registry+https://github.com/rust-lang/crates.io-index"
582
+ dependencies = [
583
+ "winapi-i686-pc-windows-gnu 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
584
+ "winapi-x86_64-pc-windows-gnu 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
585
+ ]
586
+
587
+ [[package]]
588
+ name = "winapi-build"
589
+ version = "0.1.1"
590
+ source = "registry+https://github.com/rust-lang/crates.io-index"
591
+
592
+ [[package]]
593
+ name = "winapi-i686-pc-windows-gnu"
594
+ version = "0.4.0"
595
+ source = "registry+https://github.com/rust-lang/crates.io-index"
596
+
597
+ [[package]]
598
+ name = "winapi-x86_64-pc-windows-gnu"
599
+ version = "0.4.0"
600
+ source = "registry+https://github.com/rust-lang/crates.io-index"
601
+
602
+ [[package]]
603
+ name = "winreg"
604
+ version = "0.4.0"
605
+ source = "registry+https://github.com/rust-lang/crates.io-index"
606
+ dependencies = [
607
+ "advapi32-sys 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
608
+ "kernel32-sys 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
609
+ "winapi 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)",
610
+ ]
611
+
612
+ [metadata]
613
+ "checksum advapi32-sys 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "e06588080cb19d0acb6739808aafa5f26bfb2ca015b2b6370028b44cf7cb8a9a"
614
+ "checksum aho-corasick 0.6.9 (registry+https://github.com/rust-lang/crates.io-index)" = "1e9a933f4e58658d7b12defcf96dc5c720f20832deebe3e0a19efd3b6aaeeb9e"
615
+ "checksum ansi_term 0.11.0 (registry+https://github.com/rust-lang/crates.io-index)" = "ee49baf6cb617b853aa8d93bf420db2383fab46d314482ca2803b40d5fde979b"
616
+ "checksum atty 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)" = "9a7d5b8723950951411ee34d271d99dddcc2035a16ab25310ea2c8cfd4369652"
617
+ "checksum bitflags 0.9.1 (registry+https://github.com/rust-lang/crates.io-index)" = "4efd02e230a02e18f92fc2735f44597385ed02ad8f831e7c1c1156ee5e1ab3a5"
618
+ "checksum bitflags 1.0.4 (registry+https://github.com/rust-lang/crates.io-index)" = "228047a76f468627ca71776ecdebd732a3423081fcf5125585bcd7c49886ce12"
619
+ "checksum build_const 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)" = "39092a32794787acd8525ee150305ff051b0aa6cc2abaf193924f5ab05425f39"
620
+ "checksum cfg-if 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)" = "082bb9b28e00d3c9d39cc03e64ce4cea0f1bb9b3fde493f0cbc008472d22bdf4"
621
+ "checksum clap 2.32.0 (registry+https://github.com/rust-lang/crates.io-index)" = "b957d88f4b6a63b9d70d5f454ac8011819c6efa7727858f458ab71c756ce2d3e"
622
+ "checksum crc 1.8.1 (registry+https://github.com/rust-lang/crates.io-index)" = "d663548de7f5cca343f1e0a48d14dcfb0e9eb4e079ec58883b7251539fa10aeb"
623
+ "checksum diff 0.1.11 (registry+https://github.com/rust-lang/crates.io-index)" = "3c2b69f912779fbb121ceb775d74d51e915af17aaebc38d28a592843a2dd0a3a"
624
+ "checksum embed-resource 1.1.4 (registry+https://github.com/rust-lang/crates.io-index)" = "59edbe56442f96505f79c9116006f2e26c7f5655cccdc2c1546b2528c63bd612"
625
+ "checksum env_logger 0.4.3 (registry+https://github.com/rust-lang/crates.io-index)" = "3ddf21e73e016298f5cb37d6ef8e8da8e39f91f9ec8b0df44b7deb16a9f8cd5b"
626
+ "checksum extprim 1.6.0 (registry+https://github.com/rust-lang/crates.io-index)" = "054bc2552b3f66fa8097e29e47255bfff583c08e737a67cbbb54b817ddaa5206"
627
+ "checksum fuchsia-zircon 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)" = "2e9763c69ebaae630ba35f74888db465e49e259ba1bc0eda7d06f4a067615d82"
628
+ "checksum fuchsia-zircon-sys 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)" = "3dcaa9ae7725d12cdb85b3ad99a434db70b468c09ded17e012d86b5c1010f7a7"
629
+ "checksum getopts 0.2.18 (registry+https://github.com/rust-lang/crates.io-index)" = "0a7292d30132fb5424b354f5dc02512a86e4c516fe544bb7a25e7f266951b797"
630
+ "checksum idna 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)" = "38f09e0f0b1fb55fdee1f17470ad800da77af5186a1a76c026b679358b7e844e"
631
+ "checksum itoa 0.4.3 (registry+https://github.com/rust-lang/crates.io-index)" = "1306f3464951f30e30d12373d31c79fbd52d236e5e896fd92f96ec7babbbe60b"
632
+ "checksum kernel32-sys 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)" = "7507624b29483431c0ba2d82aece8ca6cdba9382bff4ddd0f7490560c056098d"
633
+ "checksum lazy_static 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)" = "76f033c7ad61445c5b347c7382dd1237847eb1bce590fe50365dcb33d546be73"
634
+ "checksum lazy_static 1.1.0 (registry+https://github.com/rust-lang/crates.io-index)" = "ca488b89a5657b0a2ecd45b95609b3e848cf1755da332a0da46e2b2b1cb371a7"
635
+ "checksum libc 0.2.43 (registry+https://github.com/rust-lang/crates.io-index)" = "76e3a3ef172f1a0b9a9ff0dd1491ae5e6c948b94479a3021819ba7d860c8645d"
636
+ "checksum log 0.3.9 (registry+https://github.com/rust-lang/crates.io-index)" = "e19e8d5c34a3e0e2223db8e060f9e8264aeeb5c5fc64a4ee9965c062211c024b"
637
+ "checksum log 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)" = "c84ec4b527950aa83a329754b01dbe3f58361d1c5efacd1f6d68c494d08a17c6"
638
+ "checksum matches 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)" = "7ffc5c5338469d4d3ea17d269fa8ea3512ad247247c30bd2df69e68309ed0a08"
639
+ "checksum memchr 2.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "0a3eb002f0535929f1199681417029ebea04aadc0c7a4224b46be99c7f5d6a16"
640
+ "checksum num-traits 0.2.6 (registry+https://github.com/rust-lang/crates.io-index)" = "0b3a5d7cc97d6d30d8b9bc8fa19bf45349ffe46241e8816f50f62f6d6aaabee1"
641
+ "checksum openalias 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "bb1c238da0546b7e66d2d1fad509c146acff4e87f9324b73a395fdb948393e83"
642
+ "checksum peg 0.5.7 (registry+https://github.com/rust-lang/crates.io-index)" = "40df12dde1d836ed2a4c3bfc2799797e3abaf807d97520d28d6e3f3bf41a5f85"
643
+ "checksum proc-macro2 0.4.20 (registry+https://github.com/rust-lang/crates.io-index)" = "3d7b7eaaa90b4a90a932a9ea6666c95a389e424eff347f0f793979289429feee"
644
+ "checksum quote 0.3.15 (registry+https://github.com/rust-lang/crates.io-index)" = "7a6e920b65c65f10b2ae65c831a81a073a89edd28c7cce89475bff467ab4167a"
645
+ "checksum quote 0.6.9 (registry+https://github.com/rust-lang/crates.io-index)" = "63b5829244f52738cfee93b3a165c1911388675be000c888d2fae620dee8fa5b"
646
+ "checksum rand 0.3.22 (registry+https://github.com/rust-lang/crates.io-index)" = "15a732abf9d20f0ad8eeb6f909bf6868722d9a06e1e50802b6a70351f40b4eb1"
647
+ "checksum rand 0.4.3 (registry+https://github.com/rust-lang/crates.io-index)" = "8356f47b32624fef5b3301c1be97e5944ecdd595409cc5da11d05f211db6cfbd"
648
+ "checksum redox_syscall 0.1.40 (registry+https://github.com/rust-lang/crates.io-index)" = "c214e91d3ecf43e9a4e41e578973adeb14b474f2bee858742d127af75a0112b1"
649
+ "checksum redox_termios 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "7e891cfe48e9100a70a3b6eb652fef28920c117d366339687bd5576160db0f76"
650
+ "checksum regex 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)" = "9329abc99e39129fcceabd24cf5d85b4671ef7c29c50e972bc5afe32438ec384"
651
+ "checksum regex-syntax 0.5.6 (registry+https://github.com/rust-lang/crates.io-index)" = "7d707a4fa2637f2dca2ef9fd02225ec7661fe01a53623c1e6515b6916511f7a7"
652
+ "checksum resolve 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)" = "6a40df559bf6f525f5543572ca8c2a49c96c3ca0debfcb00c499dce9bf4ff548"
653
+ "checksum ruby-sys 0.2.20 (registry+https://github.com/rust-lang/crates.io-index)" = "e71509f17ce93733dc196258e168b58050490a156b04563816a8120a74ba04c7"
654
+ "checksum ruru 0.9.3 (registry+https://github.com/rust-lang/crates.io-index)" = "6486d6c50b7a08246a492a61893635c1977d41c138041d443eb603f6298e0273"
655
+ "checksum rustc_version 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)" = "138e3e0acb6c9fb258b19b67cb8abd63c00679d2851805ea151465464fe9030a"
656
+ "checksum rustfmt 0.9.0 (registry+https://github.com/rust-lang/crates.io-index)" = "0a7e11c754d828d60e699c1b2642aa3a1a217b15c57ace2801a751f8e3c1817a"
657
+ "checksum ryu 0.2.6 (registry+https://github.com/rust-lang/crates.io-index)" = "7153dd96dade874ab973e098cb62fcdbb89a03682e46b144fd09550998d4a4a7"
658
+ "checksum semver 0.9.0 (registry+https://github.com/rust-lang/crates.io-index)" = "1d7eb9ef2c18661902cc47e535f9bc51b78acd254da71d375c2f6720d9a40403"
659
+ "checksum semver-parser 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)" = "388a1df253eca08550bef6c72392cfe7c30914bf41df5269b68cbd6ff8f570a3"
660
+ "checksum serde 1.0.80 (registry+https://github.com/rust-lang/crates.io-index)" = "15c141fc7027dd265a47c090bf864cf62b42c4d228bbcf4e51a0c9e2b0d3f7ef"
661
+ "checksum serde_derive 1.0.80 (registry+https://github.com/rust-lang/crates.io-index)" = "225de307c6302bec3898c51ca302fc94a7a1697ef0845fcee6448f33c032249c"
662
+ "checksum serde_json 1.0.32 (registry+https://github.com/rust-lang/crates.io-index)" = "43344e7ce05d0d8280c5940cabb4964bea626aa58b1ec0e8c73fa2a8512a38ce"
663
+ "checksum strings 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "aa481ee1bc42fc3df8195f91f7cb43cf8f2b71b48bac40bf5381cfaf7e481f3c"
664
+ "checksum strsim 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)" = "bb4f380125926a99e52bc279241539c018323fab05ad6368b56f93d9369ff550"
665
+ "checksum syn 0.15.17 (registry+https://github.com/rust-lang/crates.io-index)" = "3391038ebc3e4ab24eb028cb0ef2f2dc4ba0cbf72ee895ed6a6fad730640b5bc"
666
+ "checksum syntex_errors 0.59.1 (registry+https://github.com/rust-lang/crates.io-index)" = "3133289179676c9f5c5b2845bf5a2e127769f4889fcbada43035ef6bd662605e"
667
+ "checksum syntex_pos 0.59.1 (registry+https://github.com/rust-lang/crates.io-index)" = "30ab669fa003d208c681f874bbc76d91cc3d32550d16b5d9d2087cf477316470"
668
+ "checksum syntex_syntax 0.59.1 (registry+https://github.com/rust-lang/crates.io-index)" = "03815b9f04d95828770d9c974aa39c6e1f6ef3114eb77a3ce09008a0d15dd142"
669
+ "checksum term 0.4.6 (registry+https://github.com/rust-lang/crates.io-index)" = "fa63644f74ce96fbeb9b794f66aff2a52d601cbd5e80f4b97123e3899f4570f1"
670
+ "checksum termion 1.5.1 (registry+https://github.com/rust-lang/crates.io-index)" = "689a3bdfaab439fd92bc87df5c4c78417d3cbe537487274e9b0b2dce76e92096"
671
+ "checksum textwrap 0.10.0 (registry+https://github.com/rust-lang/crates.io-index)" = "307686869c93e71f94da64286f9a9524c0f308a9e1c87a583de8e9c9039ad3f6"
672
+ "checksum thread_local 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)" = "c6b53e329000edc2b34dbe8545fd20e55a333362d0a321909685a19bd28c3f1b"
673
+ "checksum toml 0.4.8 (registry+https://github.com/rust-lang/crates.io-index)" = "4a2ecc31b0351ea18b3fe11274b8db6e4d82bce861bbb22e6dbed40417902c65"
674
+ "checksum ucd-util 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)" = "d0f8bfa9ff0cadcd210129ad9d2c5f145c13e9ced3d3e5d948a6213487d52444"
675
+ "checksum unicode-bidi 0.3.4 (registry+https://github.com/rust-lang/crates.io-index)" = "49f2bd0c6468a8230e1db229cff8029217cf623c767ea5d60bfbd42729ea54d5"
676
+ "checksum unicode-normalization 0.1.7 (registry+https://github.com/rust-lang/crates.io-index)" = "6a0180bc61fc5a987082bfa111f4cc95c4caff7f9799f3e46df09163a937aa25"
677
+ "checksum unicode-segmentation 1.2.1 (registry+https://github.com/rust-lang/crates.io-index)" = "aa6024fc12ddfd1c6dbc14a80fa2324d4568849869b779f6bd37e5e4c03344d1"
678
+ "checksum unicode-width 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)" = "882386231c45df4700b275c7ff55b6f3698780a650026380e72dabe76fa46526"
679
+ "checksum unicode-xid 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)" = "fc72304796d0818e357ead4e000d19c9c174ab23dc11093ac919054d20a6a7fc"
680
+ "checksum utf8-ranges 1.0.2 (registry+https://github.com/rust-lang/crates.io-index)" = "796f7e48bef87609f7ade7e06495a87d5cd06c7866e6a5cbfceffc558a243737"
681
+ "checksum vec_map 0.8.1 (registry+https://github.com/rust-lang/crates.io-index)" = "05c78687fb1a80548ae3250346c3db86a80a7cdd77bda190189f2d0a0987c81a"
682
+ "checksum version_check 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)" = "914b1a6776c4c929a602fafd8bc742e06365d4bcbe48c30f9cca5824f70dc9dd"
683
+ "checksum winapi 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)" = "167dc9d6949a9b857f3451275e911c3f44255842c1f7a76f33c55103a909087a"
684
+ "checksum winapi 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)" = "92c1eb33641e276cfa214a0522acad57be5c56b10cb348b3c5117db75f3ac4b0"
685
+ "checksum winapi-build 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "2d315eee3b34aca4797b2da6b13ed88266e6d612562a0c46390af8299fc699bc"
686
+ "checksum winapi-i686-pc-windows-gnu 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)" = "ac3b87c63620426dd9b991e5ce0329eff545bccbbb34f3be09ff6fb6ab51b7b6"
687
+ "checksum winapi-x86_64-pc-windows-gnu 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)" = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f"
688
+ "checksum winreg 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)" = "cbf285379f20d7f26abd990d9a566be9d31ab7a9d335299baaa1f0604f5f96af"
data/Cargo.toml ADDED
@@ -0,0 +1,12 @@
1
+ [package]
2
+ name = "openalias"
3
+ version = "0.1.0"
4
+ authors = ["bumi <hello@michaelbumann.com>"]
5
+
6
+ [dependencies]
7
+ ruru = "0.9.0"
8
+ openalias = "0.2.0"
9
+
10
+ [lib]
11
+ name = "openalias_rust"
12
+ crate-type = ["dylib"]
data/Gemfile ADDED
@@ -0,0 +1,6 @@
1
+ source "https://rubygems.org"
2
+
3
+ git_source(:github) {|repo_name| "https://github.com/#{repo_name}" }
4
+
5
+ # Specify your gem's dependencies in openalias.gemspec
6
+ gemspec
data/LICENSE.txt ADDED
@@ -0,0 +1,21 @@
1
+ The MIT License (MIT)
2
+
3
+ Copyright (c) 2018 bumi
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in
13
+ all copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21
+ THE SOFTWARE.
data/README.md ADDED
@@ -0,0 +1,48 @@
1
+ # OpenAlias ruby
2
+
3
+ This ruby gem allows you to lookup and read [OpenAlias](https://openalias.org) data with ruby.
4
+
5
+ OpenAlias ([openalias.org](https://openalias.org)) is an open standard for simpler addresses for any crypto currencies. [Read more here](https://openalias.org)
6
+
7
+ At its most basic, OpenAlias is a TXT DNS record on a FQDN (fully qualified domain name).
8
+ By combining this with DNS-related technologies [it has] created an aliasing standard that is extensible for developers,
9
+ intuitive and familiar for users, and can interoperate with both centralised and decentralised domain systems.
10
+
11
+ It is using the [OpenAlias rust implementation](https://github.com/nabijaczleweli/openalias.rs/) - and is simply a ruby wrapper with a native rust extension.
12
+
13
+ Maybe this is a bad idea, but I had a few minutes and wanted to try it. It works perfectly (but gem install takes a while to compile the extension)
14
+ At some point it would probably be awesome to rewrite the whole thing in pure ruby - which is likely very easy.
15
+
16
+ ## Installation
17
+
18
+ Add this line to your application's Gemfile:
19
+
20
+ ```ruby
21
+ gem 'openalias'
22
+ ```
23
+
24
+ Or install it yourself as:
25
+
26
+ $ gem install openalias
27
+
28
+ ## Usage
29
+
30
+ ```ruby
31
+ Openalias.addresses('btc@michaelbumann.com')
32
+ => [#<Openalias::CryptoAddress cryptocurrency="btc", address="3MGfEx4iaVEAy8nD4rWdocgrPo8aCR4Zfa", recipient_name="bumi">]
33
+
34
+ Openalias.addresses('donate.getmonero.org')
35
+ => [#<Openalias::CryptoAddress cryptocurrency="xmr", address="44AFFq5kSiGBoZ4NMDwYtN18obc8AemS33DBLWs3H7otXft3XjrpDtQGv7SqSsaBYBb98uNbr2VBBEt7f2wfn3RVGQBEP3A", recipient_name="Monero Development", tx_description="Donation to Monero Core Team">, #<Openalias::CryptoAddress cryptocurrency="btc", address="1KTexdemPdxSBcG55heUuTjDRYqbC5ZL8H", recipient_name="Monero Development", tx_description="Donation to Monero Core Team">]
36
+
37
+ Openalias.addresses('donate.getmonero.org')[0].recipient_name
38
+ => "Monero Development"
39
+
40
+ ```
41
+
42
+ ## Contributing
43
+
44
+ Bug reports and pull requests are welcome on GitHub at https://github.com/bumi/openalias-ruby.
45
+
46
+ ## License
47
+
48
+ The gem is available as open source under the terms of the [MIT License](http://opensource.org/licenses/MIT).
data/Rakefile ADDED
@@ -0,0 +1,9 @@
1
+ require "bundler/gem_tasks"
2
+ require "rspec/core/rake_task"
3
+ require 'thermite/tasks'
4
+
5
+ Thermite::Tasks.new
6
+
7
+ RSpec::Core::RakeTask.new(:spec)
8
+
9
+ task :default => ['thermite:build', 'thermite:test', 'spec']
data/bin/console ADDED
@@ -0,0 +1,14 @@
1
+ #!/usr/bin/env ruby
2
+
3
+ require "bundler/setup"
4
+ require "openalias"
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__)
data/bin/setup ADDED
@@ -0,0 +1,8 @@
1
+ #!/usr/bin/env bash
2
+ set -euo pipefail
3
+ IFS=$'\n\t'
4
+ set -vx
5
+
6
+ bundle install
7
+
8
+ # Do any other automated setup that you need to do here
data/ext/Rakefile ADDED
@@ -0,0 +1,5 @@
1
+ require 'thermite/tasks'
2
+
3
+ project_dir = File.dirname(File.dirname(__FILE__))
4
+ Thermite::Tasks.new(cargo_project_path: project_dir, ruby_project_path: project_dir)
5
+ task default: %w(thermite:build)
data/lib/openalias.rb ADDED
@@ -0,0 +1,13 @@
1
+ require 'thermite/fiddle'
2
+ require 'ostruct'
3
+
4
+ class Openalias
5
+ VERSION = "0.1.0"
6
+ class CryptoAddress < OpenStruct; end
7
+
8
+ toplevel_dir = File.dirname(File.dirname(__FILE__))
9
+ Thermite::Fiddle.load_module('init_openalias_rust',
10
+ cargo_project_path: toplevel_dir,
11
+ ruby_project_path: toplevel_dir)
12
+
13
+ end
data/openalias.gemspec ADDED
@@ -0,0 +1,29 @@
1
+ # coding: utf-8
2
+ lib = File.expand_path("../lib", __FILE__)
3
+ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
+
5
+ Gem::Specification.new do |spec|
6
+ spec.name = "openalias"
7
+ spec.version = "0.1.0"
8
+ spec.authors = ["bumi"]
9
+ spec.email = ["hello@michaelbumann.com"]
10
+
11
+ spec.summary = %q{OpenAlias lookup and parsing for ruby}
12
+ spec.description = %q{Wrapper around the OpenAlias rust implementation that allows to lookup and parse OpenAlias entries. (Though we should write this in pure ruby - please help)}
13
+ spec.homepage = "https://github.com/bumi/openalias-ruby"
14
+ spec.license = "MIT"
15
+
16
+ spec.files = `git ls-files -z`.split("\x0").reject do |f|
17
+ f.match(%r{^(test|spec|features)/})
18
+ end
19
+ spec.bindir = "exe"
20
+ spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
21
+ spec.require_paths = ["lib"]
22
+
23
+ spec.extensions << 'ext/Rakefile'
24
+
25
+ spec.add_development_dependency "bundler", "~> 1.15"
26
+ spec.add_development_dependency "rake", "~> 10.0"
27
+ spec.add_development_dependency "rspec", "~> 3.0"
28
+ spec.add_runtime_dependency 'thermite', '~> 0'
29
+ end
data/src/lib.rs ADDED
@@ -0,0 +1,62 @@
1
+ #[macro_use]
2
+ extern crate ruru;
3
+ extern crate openalias;
4
+
5
+ use ruru::{Array, Hash, Class, Boolean, Object, RString, Symbol};
6
+
7
+ class!(Openalias);
8
+
9
+ methods!(
10
+ Openalias,
11
+ itself,
12
+
13
+ fn addresses(address: RString) -> Array {
14
+ let mut cryptoaddresses = Array::new();
15
+ match openalias::addresses(&address.unwrap().to_string()) {
16
+ Ok(cas) => {
17
+ for c in cas {
18
+ let mut cryptoaddress = Hash::new();
19
+ cryptoaddress.store(Symbol::new("cryptocurrency"), RString::new(&c.cryptocurrency));
20
+ cryptoaddress.store(Symbol::new("address"), RString::new(&c.address));
21
+ if let Some(recipient_name) = c.recipient_name.as_ref() {
22
+ cryptoaddress.store(Symbol::new("recipient_name"), RString::new(recipient_name));
23
+ }
24
+ if let Some(tx_description) = c.tx_description.as_ref() {
25
+ cryptoaddress.store(Symbol::new("tx_description"), RString::new(tx_description));
26
+ }
27
+ if let Some(tx_amount) = c.tx_amount.as_ref() {
28
+ cryptoaddress.store(Symbol::new("tx_amount"), RString::new(tx_amount));
29
+ }
30
+ if let Some(tx_payment_id) = c.tx_payment_id.as_ref() {
31
+ cryptoaddress.store(Symbol::new("tx_payment_id"), RString::new(tx_payment_id));
32
+ }
33
+ if let Some(address_signature) = c.address_signature.as_ref() {
34
+ cryptoaddress.store(Symbol::new("address_signature"), RString::new(address_signature));
35
+ }
36
+ if let Some(&(_, checksum_ok)) = c.checksum.as_ref() {
37
+ cryptoaddress.store(Symbol::new("checksum"), Boolean::new(checksum_ok));
38
+ }
39
+ for (key, val) in &c.additional_values {
40
+ cryptoaddress.store(Symbol::new(key), RString::new(val));
41
+ }
42
+
43
+ let ca = Class::from_existing("Openalias").get_nested_class("CryptoAddress").new_instance(vec![cryptoaddress.to_any_object()]);
44
+ cryptoaddresses.push(ca);
45
+ }
46
+ return cryptoaddresses;
47
+ }
48
+ Err(cas) => {
49
+ println!("{}", cas);
50
+ return cryptoaddresses;
51
+ }
52
+ }
53
+ }
54
+ );
55
+
56
+ #[no_mangle]
57
+ pub extern fn init_openalias_rust() {
58
+ Class::from_existing("Openalias").define(|itself| {
59
+ //Class::new("OpenaliasRust", None).define(|itself| {
60
+ itself.def_self("addresses", addresses);
61
+ });
62
+ }
metadata ADDED
@@ -0,0 +1,118 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: openalias
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.1.0
5
+ platform: ruby
6
+ authors:
7
+ - bumi
8
+ autorequire:
9
+ bindir: exe
10
+ cert_chain: []
11
+ date: 2018-11-01 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: bundler
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - "~>"
18
+ - !ruby/object:Gem::Version
19
+ version: '1.15'
20
+ type: :development
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - "~>"
25
+ - !ruby/object:Gem::Version
26
+ version: '1.15'
27
+ - !ruby/object:Gem::Dependency
28
+ name: rake
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - "~>"
32
+ - !ruby/object:Gem::Version
33
+ version: '10.0'
34
+ type: :development
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - "~>"
39
+ - !ruby/object:Gem::Version
40
+ version: '10.0'
41
+ - !ruby/object:Gem::Dependency
42
+ name: rspec
43
+ requirement: !ruby/object:Gem::Requirement
44
+ requirements:
45
+ - - "~>"
46
+ - !ruby/object:Gem::Version
47
+ version: '3.0'
48
+ type: :development
49
+ prerelease: false
50
+ version_requirements: !ruby/object:Gem::Requirement
51
+ requirements:
52
+ - - "~>"
53
+ - !ruby/object:Gem::Version
54
+ version: '3.0'
55
+ - !ruby/object:Gem::Dependency
56
+ name: thermite
57
+ requirement: !ruby/object:Gem::Requirement
58
+ requirements:
59
+ - - "~>"
60
+ - !ruby/object:Gem::Version
61
+ version: '0'
62
+ type: :runtime
63
+ prerelease: false
64
+ version_requirements: !ruby/object:Gem::Requirement
65
+ requirements:
66
+ - - "~>"
67
+ - !ruby/object:Gem::Version
68
+ version: '0'
69
+ description: Wrapper around the OpenAlias rust implementation that allows to lookup
70
+ and parse OpenAlias entries. (Though we should write this in pure ruby - please
71
+ help)
72
+ email:
73
+ - hello@michaelbumann.com
74
+ executables: []
75
+ extensions:
76
+ - ext/Rakefile
77
+ extra_rdoc_files: []
78
+ files:
79
+ - ".gitignore"
80
+ - ".rspec"
81
+ - ".travis.yml"
82
+ - Cargo.lock
83
+ - Cargo.toml
84
+ - Gemfile
85
+ - LICENSE.txt
86
+ - README.md
87
+ - Rakefile
88
+ - bin/console
89
+ - bin/setup
90
+ - ext/Rakefile
91
+ - lib/openalias.rb
92
+ - openalias.gemspec
93
+ - src/lib.rs
94
+ homepage: https://github.com/bumi/openalias-ruby
95
+ licenses:
96
+ - MIT
97
+ metadata: {}
98
+ post_install_message:
99
+ rdoc_options: []
100
+ require_paths:
101
+ - lib
102
+ required_ruby_version: !ruby/object:Gem::Requirement
103
+ requirements:
104
+ - - ">="
105
+ - !ruby/object:Gem::Version
106
+ version: '0'
107
+ required_rubygems_version: !ruby/object:Gem::Requirement
108
+ requirements:
109
+ - - ">="
110
+ - !ruby/object:Gem::Version
111
+ version: '0'
112
+ requirements: []
113
+ rubyforge_project:
114
+ rubygems_version: 2.6.11
115
+ signing_key:
116
+ specification_version: 4
117
+ summary: OpenAlias lookup and parsing for ruby
118
+ test_files: []