File tree Expand file tree Collapse file tree 1 file changed +4
-17
lines changed Expand file tree Collapse file tree 1 file changed +4
-17
lines changed Original file line number Diff line number Diff line change 1
1
#! /bin/bash
2
2
3
- # Check if `--no-purge` passed as a parameter
4
- NO_PURGE=0
5
- for arg in " $@ " ; do
6
- if [ " $arg " = " --no-purge" ]; then
7
- NO_PURGE=1
8
- break
9
- fi
10
- done
11
-
12
3
# Determine the directory this script resides in. This allows invoking it from any location.
13
4
SCRIPT_DIR=" $( cd " $( dirname " ${BASH_SOURCE[0]} " ) " & > /dev/null && pwd) "
14
5
@@ -41,14 +32,10 @@ echo "*** Building chainspec..."
41
32
" $BASE_DIR /target/release/node-subtensor" build-spec --disable-default-bootnode --raw --chain $CHAIN > $FULL_PATH
42
33
echo " *** Chainspec built and output to file"
43
34
44
- if [ $NO_PURGE -eq 1 ]; then
45
- echo " *** Purging previous state skipped..."
46
- else
47
- echo " *** Purging previous state..."
48
- " $BASE_DIR /target/release/node-subtensor" purge-chain -y --base-path /tmp/bob --chain=" $FULL_PATH " > /dev/null 2>&1
49
- " $BASE_DIR /target/release/node-subtensor" purge-chain -y --base-path /tmp/alice --chain=" $FULL_PATH " > /dev/null 2>&1
50
- echo " *** Previous chainstate purged"
51
- fi
35
+ echo " *** Purging previous state..."
36
+ " $BASE_DIR /target/release/node-subtensor" purge-chain -y --base-path /tmp/bob --chain=" $FULL_PATH " > /dev/null 2>&1
37
+ " $BASE_DIR /target/release/node-subtensor" purge-chain -y --base-path /tmp/alice --chain=" $FULL_PATH " > /dev/null 2>&1
38
+ echo " *** Previous chainstate purged"
52
39
53
40
echo " *** Starting localnet nodes..."
54
41
alice_start=(
You can’t perform that action at this time.
0 commit comments