Skip to content

Commit 17dfeba

Browse files
authored
add module graph (#69)
1 parent 3389ac0 commit 17dfeba

File tree

4 files changed

+132
-5
lines changed

4 files changed

+132
-5
lines changed

.gitignore

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,6 @@
11
# Log files
22
*.log
33

4-
# bin
5-
tools/bin/*
6-
74
# generated content
85
**/*.abi
96
**/*.bin

Makefile

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
.PHONY: gomods
22
gomods: ## Install gomods
3-
go install github.com/jmank88/[email protected].5
3+
go install github.com/jmank88/[email protected].6
44

55
.PHONY: gomodtidy
66
gomodtidy: gomods
@@ -10,8 +10,13 @@ gomodtidy: gomods
1010
mockery: $(mockery) ## Install mockery.
1111
go install github.com/vektra/mockery/[email protected]
1212

13+
.PHONY: modgraph
14+
modgraph: gomods
15+
go install github.com/jmank88/[email protected]
16+
./tools/bin/modgraph > go.md
17+
1318
.PHONY: generate
14-
generate: mockery
19+
generate: mockery modgraph
1520
find . -type f -name .mockery.yaml -execdir mockery \; ## Execute mockery for all .mockery.yaml files
1621

1722
.PHONY: rm-mocked

go.md

Lines changed: 112 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,112 @@
1+
# smartcontractkit Go modules
2+
## All modules
3+
```mermaid
4+
flowchart LR
5+
6+
chain-selectors
7+
click chain-selectors href "https://github.com/smartcontractkit/chain-selectors"
8+
chainlink-automation
9+
click chainlink-automation href "https://github.com/smartcontractkit/chainlink-automation"
10+
chainlink-ccip
11+
click chainlink-ccip href "https://github.com/smartcontractkit/chainlink-ccip"
12+
chainlink-common --> chain-selectors
13+
chainlink-common --> chainlink-common/pkg/chipingress
14+
chainlink-common --> chainlink-common/pkg/values
15+
chainlink-common --> chainlink-protos/billing/go
16+
chainlink-common --> chainlink-protos/cre/go
17+
chainlink-common --> chainlink-protos/storage-service
18+
chainlink-common --> chainlink-protos/workflows/go
19+
chainlink-common --> freeport
20+
chainlink-common --> grpc-proxy
21+
chainlink-common --> libocr
22+
click chainlink-common href "https://github.com/smartcontractkit/chainlink-common"
23+
chainlink-common/pkg/chipingress
24+
click chainlink-common/pkg/chipingress href "https://github.com/smartcontractkit/chainlink-common"
25+
chainlink-common/pkg/values
26+
click chainlink-common/pkg/values href "https://github.com/smartcontractkit/chainlink-common"
27+
chainlink-cosmos
28+
click chainlink-cosmos href "https://github.com/smartcontractkit/chainlink-cosmos"
29+
chainlink-data-streams
30+
click chainlink-data-streams href "https://github.com/smartcontractkit/chainlink-data-streams"
31+
chainlink-feeds
32+
click chainlink-feeds href "https://github.com/smartcontractkit/chainlink-feeds"
33+
chainlink-framework/capabilities --> chainlink-common
34+
click chainlink-framework/capabilities href "https://github.com/smartcontractkit/chainlink-framework"
35+
chainlink-framework/chains --> chainlink-framework/multinode
36+
click chainlink-framework/chains href "https://github.com/smartcontractkit/chainlink-framework"
37+
chainlink-framework/metrics --> chainlink-common
38+
click chainlink-framework/metrics href "https://github.com/smartcontractkit/chainlink-framework"
39+
chainlink-framework/multinode --> chainlink-framework/metrics
40+
click chainlink-framework/multinode href "https://github.com/smartcontractkit/chainlink-framework"
41+
chainlink-framework/tools/evm-chain-bindings --> chainlink/v2
42+
click chainlink-framework/tools/evm-chain-bindings href "https://github.com/smartcontractkit/chainlink-framework"
43+
chainlink-protos/billing/go
44+
click chainlink-protos/billing/go href "https://github.com/smartcontractkit/chainlink-protos"
45+
chainlink-protos/cre/go
46+
click chainlink-protos/cre/go href "https://github.com/smartcontractkit/chainlink-protos"
47+
chainlink-protos/storage-service
48+
click chainlink-protos/storage-service href "https://github.com/smartcontractkit/chainlink-protos"
49+
chainlink-protos/workflows/go
50+
click chainlink-protos/workflows/go href "https://github.com/smartcontractkit/chainlink-protos"
51+
chainlink-solana
52+
click chainlink-solana href "https://github.com/smartcontractkit/chainlink-solana"
53+
chainlink-starknet/relayer
54+
click chainlink-starknet/relayer href "https://github.com/smartcontractkit/chainlink-starknet"
55+
chainlink/v2 --> chainlink-automation
56+
chainlink/v2 --> chainlink-ccip
57+
chainlink/v2 --> chainlink-common
58+
chainlink/v2 --> chainlink-cosmos
59+
chainlink/v2 --> chainlink-data-streams
60+
chainlink/v2 --> chainlink-feeds
61+
chainlink/v2 --> chainlink-solana
62+
chainlink/v2 --> chainlink-starknet/relayer
63+
chainlink/v2 --> tdh2/go/ocr2/decryptionplugin
64+
chainlink/v2 --> tdh2/go/tdh2
65+
chainlink/v2 --> wsrpc
66+
click chainlink/v2 href "https://github.com/smartcontractkit/chainlink"
67+
freeport
68+
click freeport href "https://github.com/smartcontractkit/freeport"
69+
grpc-proxy
70+
click grpc-proxy href "https://github.com/smartcontractkit/grpc-proxy"
71+
libocr
72+
click libocr href "https://github.com/smartcontractkit/libocr"
73+
tdh2/go/ocr2/decryptionplugin
74+
click tdh2/go/ocr2/decryptionplugin href "https://github.com/smartcontractkit/tdh2"
75+
tdh2/go/tdh2
76+
click tdh2/go/tdh2 href "https://github.com/smartcontractkit/tdh2"
77+
wsrpc
78+
click wsrpc href "https://github.com/smartcontractkit/wsrpc"
79+
80+
subgraph chainlink-common-repo[chainlink-common]
81+
chainlink-common
82+
chainlink-common/pkg/chipingress
83+
chainlink-common/pkg/values
84+
end
85+
click chainlink-common-repo href "https://github.com/smartcontractkit/chainlink-common"
86+
87+
subgraph chainlink-framework-repo[chainlink-framework]
88+
chainlink-framework/capabilities
89+
chainlink-framework/chains
90+
chainlink-framework/metrics
91+
chainlink-framework/multinode
92+
chainlink-framework/tools/evm-chain-bindings
93+
end
94+
click chainlink-framework-repo href "https://github.com/smartcontractkit/chainlink-framework"
95+
96+
subgraph chainlink-protos-repo[chainlink-protos]
97+
chainlink-protos/billing/go
98+
chainlink-protos/cre/go
99+
chainlink-protos/storage-service
100+
chainlink-protos/workflows/go
101+
end
102+
click chainlink-protos-repo href "https://github.com/smartcontractkit/chainlink-protos"
103+
104+
subgraph tdh2-repo[tdh2]
105+
tdh2/go/ocr2/decryptionplugin
106+
tdh2/go/tdh2
107+
end
108+
click tdh2-repo href "https://github.com/smartcontractkit/tdh2"
109+
110+
classDef outline stroke-dasharray:6,fill:none;
111+
class chainlink-common-repo,chainlink-framework-repo,chainlink-protos-repo,tdh2-repo outline
112+
```

tools/bin/modgraph

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
#!/usr/bin/env bash
2+
3+
# Generates go.md
4+
5+
set -e
6+
7+
echo "# smartcontractkit Go modules
8+
## All modules
9+
\`\`\`mermaid
10+
flowchart LR
11+
"
12+
gomods graph | modgraph -prefix github.com/smartcontractkit/
13+
echo "\`\`\`"

0 commit comments

Comments
 (0)