-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpackage.js
More file actions
82 lines (73 loc) · 1.55 KB
/
package.js
File metadata and controls
82 lines (73 loc) · 1.55 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
Package.describe({
name: 'wieldo:crypto',
version: '0.1.0',
summary: 'Abstraction layer for Tweetnacl',
git: 'https://github.com/wieldo/crypto.git'
});
Npm.depends({
tweetnacl: '0.14.0',
'tweetnacl-util': '0.13.3'
});
Package.onUse(function cryptoOnUse(api) {
api.versionsFrom('METEOR@1.2.1');
api.use([
'ecmascript',
'stevezhu:lodash@4.5.0',
'check@1.1.0'
]);
api.imply([
'stevezhu:lodash@4.5.0',
'check@1.1.0'
]);
api.addFiles([
'.npm/package/node_modules/tweetnacl/nacl-fast.js',
'.npm/package/node_modules/tweetnacl-util/nacl-util.js'
], 'client');
api.addFiles([
'index',
'utils',
'sym',
'asym',
'export'
].map(function(file) {
return 'src/' + file + '.js';
}), 'client');
api.export([
'Crypto'
], 'client');
});
Package.onTest(function cryptoOnTest(api) {
api.use([
'ecmascript',
'wieldo:crypto',
'sanjo:jasmine@0.21.0',
'velocity:helpers@0.5.0',
'velocity:html-reporter@0.9.1'
]);
api.addFiles([
'export',
// utils
'utils/key',
'utils/key-pair',
'utils/nonce',
'utils/random',
'utils/encode',
'utils/decode',
// sym
'sym/encrypt',
'sym/encrypt-string',
'sym/encrypt-object',
'sym/decrypt',
'sym/decrypt-string',
'sym/decrypt-object',
// asym
'asym/encrypt',
'asym/encrypt-string',
'asym/encrypt-object',
'asym/decrypt',
'asym/decrypt-string',
'asym/decrypt-object'
].map(function(file) {
return 'tests/jasmine/client/' + file + '.js';
}), 'client');
});