-
Notifications
You must be signed in to change notification settings - Fork 39
/
codegen.js
executable file
·88 lines (86 loc) · 2.65 KB
/
codegen.js
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
83
84
85
86
87
88
#!/usr/bin/env node
const { join } = require('path');
const telescope = require('@osmonauts/telescope').default;
telescope({
protoDirs: [
'cosmos-sdk-0.45/proto',
'cosmos-sdk-0.45/third_party/proto',
'wasmd-0.28/proto',
'wasmd-0.28/third_party/proto',
],
outPath: join(__dirname, '/../src'),
options: {
logLevel: 0,
useSDKTypes: false,
tsDisable: {
disableAll: false
},
eslintDisable: {
disableAll: true
},
bundle: {
enabled: false
},
prototypes: {
includePackageVar: true,
excluded: {
protos: [
'cosmos/authz/v1beta1/event.proto',
'cosmos/base/reflection/v2alpha1/reflection.proto',
'cosmos/crypto/secp256r1/keys.proto',
'ibc/core/port/v1/query.proto',
'ibc/lightclients/solomachine/v2/solomachine.proto',
'tendermint/libs/bits/types.proto',
'google/api/httpbody.proto',
'tendermint/blockchain/types.proto',
'tendermint/consensus/types.proto',
'tendermint/consensus/wal.proto',
'tendermint/mempool/types.proto',
'tendermint/p2p/conn.proto',
'tendermint/p2p/pex.proto',
'tendermint/privval/types.proto',
'tendermint/rpc/grpc/types.proto',
'tendermint/state/types.proto',
'tendermint/statesync/types.proto',
'tendermint/store/types.proto',
'tendermint/types/canonical.proto',
'tendermint/types/events.proto',
]
},
methods: {
fromJSON: true,
toJSON: true
},
typingsFormat: {
useDeepPartial: false,
useExact: false,
timestamp: 'timestamp',
duration: 'duration'
}
},
lcdClients: {
enabled: false
},
rpcClients: {
enabled: true,
inline: true,
extensions: false,
camelCase: false,
enabledServices: [
'Msg',
'Query',
'Service',
'ReflectionService',
'ABCIApplication'
]
},
aminoEncoding: {
enabled: false
}
}
}).then(() => {
console.log('✨ All Done!');
}, (e) => {
console.error(e);
process.exit(1);
});