Skip to content

Commit

Permalink
Introduce default-members to the workspace root (#1420)
Browse files Browse the repository at this point in the history
  • Loading branch information
s0me0ne-unkn0wn authored and Daanvdplas committed Sep 11, 2023
1 parent 8eafe58 commit a61cf30
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 9 deletions.
10 changes: 5 additions & 5 deletions .gitlab/pipeline/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,7 @@ build-short-benchmark:
- .run-immediately
- .collect-artifacts
script:
- cargo build --profile release --locked --features=runtime-benchmarks --bin polkadot
- cargo build --profile release --locked --features=runtime-benchmarks --bin polkadot --workspace
- mkdir -p artifacts
- target/release/polkadot --version
- cp ./target/release/polkadot ./artifacts/
Expand All @@ -183,7 +183,7 @@ build-linux-stable-cumulus:
RUSTFLAGS: "-Cdebug-assertions=y -Dwarnings"
script:
- echo "___Building a binary, please refrain from using it in production since it goes with the debug assertions.___"
- time cargo build --release --locked --bin polkadot-parachain
- time cargo build --release --locked -p polkadot-parachain-bin --bin polkadot-parachain
- echo "___Packing the artifacts___"
- mkdir -p ./artifacts
- mv ./target/release/polkadot-parachain ./artifacts/.
Expand All @@ -203,7 +203,7 @@ build-test-parachain:
RUSTFLAGS: "-Cdebug-assertions=y -Dwarnings"
script:
- echo "___Building a binary, please refrain from using it in production since it goes with the debug assertions.___"
- time cargo build --release --locked --bin test-parachain
- time cargo build --release --locked -p cumulus-test-service --bin test-parachain
- echo "___Packing the artifacts___"
- mkdir -p ./artifacts
- mv ./target/release/test-parachain ./artifacts/.
Expand Down Expand Up @@ -290,7 +290,7 @@ build-short-benchmark-cumulus:
- .run-immediately
- .collect-artifacts
script:
- cargo build --profile release --locked --features=runtime-benchmarks --bin polkadot-parachain
- cargo build --profile release --locked --features=runtime-benchmarks -p polkadot-parachain-bin --bin polkadot-parachain
- mkdir -p artifacts
- target/release/polkadot-parachain --version
- cp ./target/release/polkadot-parachain ./artifacts/
Expand All @@ -316,7 +316,7 @@ build-linux-substrate:
# see https://github.com/paritytech/ci_cd/issues/682#issuecomment-1340953589
- git checkout -B "$CI_COMMIT_REF_NAME" "$CI_COMMIT_SHA"
script:
- WASM_BUILD_NO_COLOR=1 time cargo build --locked --release
- WASM_BUILD_NO_COLOR=1 time cargo build --locked --release -p node-cli
- mv $CARGO_TARGET_DIR/release/substrate-node ./artifacts/substrate/substrate
- echo -n "Substrate version = "
- if [ "${CI_COMMIT_TAG}" ]; then
Expand Down
2 changes: 1 addition & 1 deletion .gitlab/pipeline/check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ check-try-runtime:
- time cargo check --locked -p parachain-template-node --features try-runtime
# add after https://github.com/paritytech/substrate/pull/14502 is merged
# experimental code may rely on try-runtime and vice-versa
- time cargo check --locked --features try-runtime,experimental
- time cargo check --locked --all --features try-runtime,experimental

cargo-fmt-manifest:
stage: check
Expand Down
6 changes: 3 additions & 3 deletions .gitlab/pipeline/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ test-linux-stable-runtime-benchmarks:
# but still want to have debug assertions.
RUSTFLAGS: "-Cdebug-assertions=y -Dwarnings"
script:
- time cargo nextest run --features runtime-benchmarks benchmark --locked --cargo-profile testnet
- time cargo nextest run --workspace --features runtime-benchmarks benchmark --locked --cargo-profile testnet

# these ones can be really slow so it's better to run them separately
test-linux-stable-slow:
Expand Down Expand Up @@ -185,7 +185,7 @@ test-doc:
# but still want to have debug assertions.
RUSTFLAGS: "-Cdebug-assertions=y -Dwarnings"
script:
- time cargo test --doc
- time cargo test --doc --workspace

test-rustdoc:
stage: test
Expand Down Expand Up @@ -368,7 +368,7 @@ quick-benchmarks:
WASM_BUILD_NO_COLOR: 1
WASM_BUILD_RUSTFLAGS: "-C debug-assertions -D warnings"
script:
- time cargo run --locked --release --features runtime-benchmarks -- benchmark pallet --execution wasm --wasm-execution compiled --chain dev --pallet "*" --extrinsic "*" --steps 2 --repeat 1
- time cargo run --locked --release -p node-cli --bin substrate-node --features runtime-benchmarks -- benchmark pallet --execution wasm --wasm-execution compiled --chain dev --pallet "*" --extrinsic "*" --steps 2 --repeat 1

test-frame-examples-compile-to-wasm:
# into one job
Expand Down
1 change: 1 addition & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -452,6 +452,7 @@ members = [
"substrate/utils/prometheus",
"substrate/utils/wasm-builder",
]
default-members = [ "polkadot" ]

[profile.release]
# Polkadot runtime requires unwinding.
Expand Down
1 change: 1 addition & 0 deletions polkadot/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ readme = "README.md"
authors.workspace = true
edition.workspace = true
version = "1.0.0"
default-run = "polkadot"

[dependencies]
color-eyre = { version = "0.6.1", default-features = false }
Expand Down

0 comments on commit a61cf30

Please sign in to comment.