Skip to content
Snippets Groups Projects
Commit 17ecc05a authored by bgallois's avatar bgallois Committed by Hugo Trentesaux
Browse files

use git shallow copy

parent 3c9a6fd4
No related branches found
No related tags found
1 merge request!258Upgrade to polkadot-v1.9.0
[alias]
sanity-gdev = "test -p duniter-live-tests --test sanity_gdev -- --nocapture"
tu = "test --workspace --exclude duniter-end2end-tests --exclude duniter-live-tests --features constant-fees"
sanity-gdev = "test -Zgit=shallow-deps -p duniter-live-tests --test sanity_gdev -- --nocapture"
tu = "test -Zgit=shallow-deps --workspace --exclude duniter-end2end-tests --exclude duniter-live-tests --features constant-fees"
# `te` and `cucumber` are synonyms
te = "test -p duniter-end2end-tests --test cucumber_tests --features constant-fees --"
cucumber-build = "build --features constant-fees"
cucumber = "test -p duniter-end2end-tests --test cucumber_tests --"
ta = "test --workspace --exclude duniter-live-tests --features constant-fees"
tb = "test --features runtime-benchmarks -p"
rbp = "run --release --features runtime-benchmarks -- benchmark pallet --chain=dev --steps=50 --repeat=20 --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --header=./file_header.txt --output=. --pallet"
xtask = "run --package xtask --"
cucumber-node = "run -- --chain=gdev_dev --execution=Native --sealing=manual --force-authoring --rpc-cors=all --tmp --ws-port 9944 --alice --features constant-fees"
cucumber-build = "build -Zgit=shallow-deps --features constant-fees"
cucumber = "test -Zgit=shallow-deps -p duniter-end2end-tests --test cucumber_tests --"
ta = "test -Zgit=shallow-deps --workspace --exclude duniter-live-tests --features constant-fees"
tb = "test -Zgit=shallow-deps --features runtime-benchmarks -p"
rbp = "run -Zgit=shallow-deps --release --features runtime-benchmarks -- benchmark pallet --chain=dev --steps=50 --repeat=20 --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --header=./file_header.txt --output=. --pallet"
xtask = "run -Zgit=shallow-deps --package xtask --"
cucumber-node = "run -Zgit=shallow-deps -- --chain=gdev_dev --execution=Native --sealing=manual --force-authoring --rpc-cors=all --tmp --ws-port 9944 --alice --features constant-fees"
......@@ -73,7 +73,7 @@ fmt_and_clippy:
- cargo fmt -- --version
- cargo fmt -- --check
- cargo clippy -- -V
- cargo clippy --features runtime-benchmarks --all --tests -- -D warnings
- cargo clippy -Zgit=shallow-deps --features runtime-benchmarks --all --tests -- -D warnings
run_benchmarks:
extends: .env
......@@ -86,7 +86,7 @@ run_benchmarks:
- if: '$CI_MERGE_REQUEST_ID || $CI_COMMIT_BRANCH == "master"'
- when: manual
script:
- cargo build --release --features runtime-benchmarks
- cargo build -Zgit=shallow-deps --release --features runtime-benchmarks
- target/release/duniter benchmark storage --chain=dev --mul=2 --state-version=1
- target/release/duniter benchmark overhead --chain=dev --wasm-execution=compiled --warmup=1 --repeat=100
- target/release/duniter benchmark pallet --chain=dev --steps=5 --repeat=2 --pallet="*" --extrinsic="*" --wasm-execution=compiled
......@@ -108,7 +108,7 @@ gdev_build:
script:
- apt-get update
- apt-get install -y clang cmake protobuf-compiler
- cargo build --no-default-features --features gtest
- cargo build -Zgit=shallow-deps --no-default-features --features gtest
gdev_srtool_build:
stage: build
......@@ -316,8 +316,8 @@ create_g1_data:
script:
- apt-get update
- apt-get install -y clang cmake protobuf-compiler
- cargo run ${FEATURES} -- build-spec --chain=${RUNTIME}_live > release/${RUNTIME}.json
- cargo run ${FEATURES} -- build-spec --chain=release/${RUNTIME}.json --disable-default-bootnode --raw > release/${RUNTIME}-raw.json
- cargo run -Zgit=shallow-deps ${FEATURES} -- build-spec --chain=${RUNTIME}_live > release/${RUNTIME}.json
- cargo run -Zgit=shallow-deps ${FEATURES} -- build-spec --chain=release/${RUNTIME}.json --disable-default-bootnode --raw > release/${RUNTIME}-raw.json
- cp node/specs/${RUNTIME}_client-specs.yaml release/
artifacts:
expire_in: never
......
This diff is collapsed.
......@@ -48,8 +48,8 @@ ARG chain="gdev"
RUN set -x && \
cat /root/dynenv && \
. /root/dynenv && \
cargo build --locked $CARGO_OPTIONS --no-default-features $BENCH_OPTIONS --features $chain --target "$RUST_ARCH_TRIPLET" && \
cargo build --locked $CARGO_OPTIONS --target "$RUST_ARCH_TRIPLET" --package distance-oracle && \
cargo build -Zgit=shallow-deps --locked $CARGO_OPTIONS --no-default-features $BENCH_OPTIONS --features $chain --target "$RUST_ARCH_TRIPLET" && \
cargo build -Zgit=shallow-deps --locked $CARGO_OPTIONS --target "$RUST_ARCH_TRIPLET" --package distance-oracle && \
mkdir -p build && \
mv target/$RUST_ARCH_TRIPLET/$TARGET_FOLDER/duniter build/ && \
mv target/$RUST_ARCH_TRIPLET/$TARGET_FOLDER/distance-oracle build/
......@@ -58,7 +58,7 @@ RUN set -x && \
ARG cucumber=0
RUN if [ "$cucumber" != 0 ] && [ "$TARGETPLATFORM" = "$BUILDPLATFORM" ]; then \
cargo ta && \
cargo test --workspace --exclude duniter-end2end-tests --exclude duniter-live-tests --features=runtime-benchmarks,constant-fees \
cargo test -Zgit=shallow-deps --workspace --exclude duniter-end2end-tests --exclude duniter-live-tests --features=runtime-benchmarks,constant-fees \
cd target/debug/deps/ && \
rm cucumber_tests-*.d && \
mv cucumber_tests* ../../../build/duniter-cucumber; \
......
......@@ -10,6 +10,8 @@ ParityTech frequently releases upgrades of the polkadot-sdk. For each upgrade, D
* Create a new branch: `git checkout -b duniter-polkadot-v1.9.0`
* Rebase the branch, keeping only specific commits: "fix treasury benchmarks when no SpendOrigin", "allow manual seal to produce non-empty blocks with BABE", "add custom pallet-balance GenesisConfig", and "remove pallet-balances upgrade_account extrinsic".
* Push the new branch: `git push`
* Create the lightweight branch that drops the non-Substrate parts of the repository using the command `git subtree split --prefix substrate/ --branch duniter-substrate-light-v1.9.0`.
* Checkout and push the new branch.
## 2. Upgrade duniter subxt
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment