-
Notifications
You must be signed in to change notification settings - Fork 45
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore(rpc): generate latest spec (#60)
Co-authored-by: Maciej Kamiński <[email protected]>
- Loading branch information
Showing
17 changed files
with
8,767 additions
and
53 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
SRC_DIR ?= src/v0_7_1 | ||
|
||
define generate_spec | ||
echo "Generating types for $(1)"; | ||
openrpc-gen --config $(1).toml --document $(1).json --output $(1).rs ; | ||
endef | ||
|
||
BASE_NAMES := starknet_api_openrpc starknet_trace_api_openrpc starknet_write_api | ||
# Default target that depends on all generated .rs files | ||
all: | ||
$(foreach file,$(BASE_NAMES),$(call generate_spec,$(SRC_DIR)/$(file))) | ||
|
||
# Phony target to avoid conflicts with actual files | ||
.PHONY: all |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
//! v0.7.1 of the API. | ||
pub use crate::custom::{ | ||
BlockId, BroadcastedDeclareTxn, BroadcastedDeployAccountTxn, BroadcastedInvokeTxn, | ||
SyncingStatus, | ||
}; | ||
|
||
mod starknet_api_openrpc; | ||
mod starknet_trace_api_openrpc; | ||
mod starknet_write_api; | ||
|
||
pub use self::starknet_api_openrpc::*; | ||
pub use self::starknet_trace_api_openrpc::*; | ||
pub use self::starknet_write_api::*; |
Oops, something went wrong.