Skip to content

Commit 8685688

Browse files
committed
python3 scripts/generate_llms.py
1 parent 5b22496 commit 8685688

File tree

1 file changed

+22
-29
lines changed

1 file changed

+22
-29
lines changed

llms.txt

Lines changed: 22 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -32917,8 +32917,8 @@ First, you'll update the runtime's `Cargo.toml` file to include the Utility pall
3291732917

3291832918
1. Open the `runtime/Cargo.toml` file and locate the `[dependencies]` section. Add pallet-utility as one of the features for the `polkadot-sdk` dependency with the following line:
3291932919

32920-
```toml hl_lines="4" title="Cargo.toml"
32921-
32920+
```toml hl_lines="4" title="runtime/Cargo.toml"
32921+
[dependencies]
3292232922
...
3292332923
"pallet-utility",
3292432924
...
@@ -32928,18 +32928,19 @@ First, you'll update the runtime's `Cargo.toml` file to include the Utility pall
3292832928
2. In the same `[dependencies]` section, add the custom pallet that you built from scratch with the following line:
3292932929

3293032930
```toml hl_lines="3" title="Cargo.toml"
32931-
32931+
[dependencies]
3293232932
...
32933-
32933+
custom-pallet = { path = "../pallets/custom-pallet", default-features = false }
3293432934
```
3293532935

3293632936
3. In the `[features]` section, add the custom pallet to the `std` feature list:
3293732937

3293832938
```toml hl_lines="5" title="Cargo.toml"
32939-
default = ["std"]
32939+
[features]
32940+
default = ["std"]
3294032941
std = [
3294132942
...
32942-
]
32943+
"custom-pallet/std",
3294332944
```
3294432945

3294532946
3. Save the changes and close the `Cargo.toml` file
@@ -33051,24 +33052,18 @@ on-chain-release-build = ["metadata-hash"]
3305133052

3305233053
Update your root parachain template's `Cargo.toml` file to include you custom pallet as dependency. Follow these steps:
3305333054

33054-
1. Open the `./Cargo.toml` file and locate the `[workspace]` section. Add the custom-pallet as a member of the workspace:
33055+
1. Open the `./Cargo.toml` file and locate the `[workspace]` section. Make sure the custom-pallet is a member of the workspace:
3305533056

33056-
```toml hl_lines="6" title="Cargo.toml"
33057-
default-members = ["pallets/template", "runtime"]
33057+
```toml hl_lines="4" title="Cargo.toml"
33058+
[workspace]
33059+
default-members = ["pallets/template", "runtime"]
3305833060
members = [
33059-
"node",
33061+
"node", "pallets/custom-pallet",
3306033062
"pallets/template",
33061-
"pallets/custom-pallet",
3306233063
"runtime",
3306333064
]
3306433065
```
33065-
2. In the `[workspace.dependencies]` section. Add the custom-pallet with the following line:
3306633066

33067-
```toml hl_lines="4" title="Cargo.toml"
33068-
parachain-template-runtime = { path = "./runtime", default-features = false }
33069-
pallet-parachain-template = { path = "./pallets/template", default-features = false }
33070-
custom-pallet = { path = "./pallets/custom-pallet", default-features = false }
33071-
```
3307233067
???- code "./Cargo.toml"
3307333068

3307433069
```rust title="./Cargo.toml"
@@ -33082,18 +33077,15 @@ edition = "2021"
3308233077
[workspace]
3308333078
default-members = ["pallets/template", "runtime"]
3308433079
members = [
33085-
"node",
33080+
"node", "pallets/custom-pallet",
3308633081
"pallets/template",
33087-
"pallets/custom-pallet",
3308833082
"runtime",
3308933083
]
3309033084
resolver = "2"
3309133085

3309233086
[workspace.dependencies]
3309333087
parachain-template-runtime = { path = "./runtime", default-features = false }
3309433088
pallet-parachain-template = { path = "./pallets/template", default-features = false }
33095-
custom-pallet = { path = "./pallets/custom-pallet", default-features = false }
33096-
3309733089
clap = { version = "4.5.13" }
3309833090
color-print = { version = "0.3.4" }
3309933091
docify = { version = "0.2.9" }
@@ -33129,7 +33121,7 @@ Configure the pallets by implementing their `Config` trait and update the runtim
3312933121

3313033122
1. Add the `OriginCaller` import:
3313133123

33132-
```rust title="mod.rs" hl_lines="2"
33124+
```rust title="mod.rs" hl_lines="8"
3313333125
use super::OriginCaller;
3313433126
...
3313533127
```
@@ -34656,7 +34648,7 @@ For comprehensive information about benchmarking concepts, refer to the [Benchma
3465634648

3465734649
Follow these steps to prepare your environment for pallet benchmarking:
3465834650

34659-
1. Install the [`frame-omni-bencher`](https://crates.io/crates/frame-omni-bencher){target=\_blank} command-line tool:
34651+
1. Install the [`frame-omni-bencher`](https://crates.io/crates/frame-omni-bencher/{{dependencies.repositories.polkadot_sdk_parachain_template.frame_omni_bencher_version}}){target=\_blank} command-line tool:
3466034652

3466134653
```bash
3466234654
cargo install --locked frame-omni-bencher@{{dependencies.repositories.polkadot_sdk_parachain_template.frame_omni_bencher_version}}
@@ -34702,16 +34694,17 @@ runtime-benchmarks = ["frame/runtime-benchmarks"]
3470234694

3470334695
2. Enable runtime benchmarking for your pallet in `runtime/Cargo.toml`:
3470434696
```toml hl_lines="6" title="Cargo.toml"
34705-
"pallet-parachain-template/runtime-benchmarks",
34697+
runtime-benchmarks = [
34698+
"cumulus-pallet-parachain-system/runtime-benchmarks",
34699+
"hex-literal",
34700+
"pallet-parachain-template/runtime-benchmarks",
3470634701
"polkadot-sdk/runtime-benchmarks",
34702+
"custom-pallet/runtime-benchmarks",
3470734703
]
34708-
34709-
try-runtime = [
34710-
"cumulus-pallet-parachain-system/try-runtime",
3471134704
```
3471234705

3471334706
4. Set up the benchmarking module in your pallet:
34714-
1. Create a new `benchmarking.rs` file in your pallet directory:
34707+
1. Create a benchmarking.rs file in your pallet's src/ directory:
3471534708
```bash
3471634709
touch benchmarking.rs
3471734710
```
@@ -36070,7 +36063,7 @@ rustup component add rust-src --toolchain 1.86-aarch64-apple-darwin
3607036063

3607136064
This tutorial requires two essential tools:
3607236065

36073-
- [**Chain spec builder**](https://crates.io/crates/staging-chain-spec-builder/{{dependencies.crates.chain_spec_builder.version}}){target=\_blank} - is a Polkadot SDK utility for generating chain specifications. Refer to the [Generate Chain Specs](/develop/parachains/deployment/generate-chain-specs/){target=\_blank} documentation for detailed usage.
36066+
- [**Chain spec builder**](https://crates.io/crates/staging-chain-spec-builder/{{dependencies.repositories.polkadot_sdk_parachain_template.chain_spec_builder_version}}){target=\_blank} - is a Polkadot SDK utility for generating chain specifications. Refer to the [Generate Chain Specs](/develop/parachains/deployment/generate-chain-specs/){target=\_blank} documentation for detailed usage.
3607436067

3607536068
Install it by executing the following command:
3607636069

0 commit comments

Comments
 (0)