Skip to content

Commit bc8bd6c

Browse files
committed
attempt to use buf and create a buildable plan
1 parent 7388805 commit bc8bd6c

File tree

11 files changed

+9277
-20
lines changed

11 files changed

+9277
-20
lines changed

cabal.project

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,7 @@ packages:
2020
cardano-api
2121
cardano-api-gen
2222
cardano-wasm
23-
-- TODO fix potential issues with build-type: Custom and protoc and reenable
24-
-- cardano-rpc
23+
cardano-rpc
2524

2625
extra-packages: Cabal, process
2726

@@ -56,6 +55,19 @@ write-ghc-environment-files: always
5655
jobs: $ncpus
5756
semaphore: True
5857

58+
constraints:
59+
, hedgehog == 1.5
60+
, lifted-async == 0.10.2.7
61+
, random == 1.2.1.3
62+
, tls == 2.1.6
63+
, optparse-applicative==0.18.1.0
64+
, kes-agent == 0.1.0.1
65+
66+
allow-newer:
67+
-- https://github.com/kapralVV/Unique/issues/11
68+
, Unique:hashable
69+
, kes-agent:filepath
70+
5971
if impl (ghc >= 9.12)
6072
allow-newer:
6173
-- https://github.com/kapralVV/Unique/issues/11

cardano-rpc/buf.gen.yaml

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
version: v1
2+
3+
managed:
4+
enabled: true
5+
6+
plugins:
7+
# node
8+
# - plugin: es
9+
# out: gen/node/src
10+
# opt:
11+
# - target=ts
12+
#
13+
# - plugin: connect-es
14+
# out: gen/node/src
15+
# opt:
16+
# - target=ts
17+
#
18+
# - plugin: buf.build/bufbuild/protoschema-jsonschema
19+
# out: gen/jsonschema/schema
20+
21+
# haskell
22+
23+
- plugin: haskell-protolens
24+
path: proto-lens-protoc
25+
out: src
26+

cardano-rpc/cardano-rpc.cabal

Lines changed: 2 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -17,19 +17,11 @@ license-files:
1717
LICENSE
1818
NOTICE
1919

20-
build-type: Custom
20+
build-type: Simple
2121
extra-doc-files:
2222
CHANGELOG.md
2323
README.md
2424

25-
extra-source-files: proto/**/*.proto
26-
27-
custom-setup
28-
setup-depends:
29-
Cabal >=3.0 && <3.13,
30-
base >=4.14 && <5,
31-
proto-lens-setup >=0.4 && <0.5,
32-
3325
common project-config
3426
default-language: Haskell2010
3527
default-extensions:
@@ -80,14 +72,6 @@ library
8072

8173
autogen-modules:
8274
Paths_cardano_rpc
83-
Proto.Cardano.Rpc.Node
84-
Proto.Cardano.Rpc.Node_Fields
85-
Proto.Utxorpc.V1alpha.Cardano.Cardano
86-
Proto.Utxorpc.V1alpha.Cardano.Cardano_Fields
87-
Proto.Utxorpc.V1alpha.Query.Query
88-
Proto.Utxorpc.V1alpha.Query.Query_Fields
89-
Proto.Utxorpc.V1alpha.Submit.Submit
90-
Proto.Utxorpc.V1alpha.Submit.Submit_Fields
9175

9276
build-depends:
9377
aeson,
@@ -124,7 +108,7 @@ test-suite cardano-rpc-test
124108
cardano-ledger-core,
125109
cardano-rpc,
126110
containers,
127-
hedgehog >=1.1,
111+
hedgehog ^>=1.5,
128112
rio,
129113
tasty,
130114
tasty-hedgehog,

0 commit comments

Comments
 (0)