Skip to content

Commit f64ed50

Browse files
remove suffix s from sleep commands for mac os compatible
1 parent e9cb88f commit f64ed50

File tree

8 files changed

+40
-40
lines changed

8 files changed

+40
-40
lines changed

all-in-one.sh

+5-5
Original file line numberDiff line numberDiff line change
@@ -119,20 +119,20 @@ cd "$AIO_DIR_CHAIN"
119119
echo "> [Chain 1]"
120120
./1_prepare-genesis.sh 1
121121
[ $? -eq 0 ] || { echo >&2 "ERR AIO: Operation failed (genesis)"; exit 1; }
122-
sleep 2s
122+
sleep 2
123123
./2_build-docker-image.sh 1
124124
[ $? -eq 0 ] || { echo >&2 "ERR AIO: Operation failed (build docker image)"; exit 1; }
125-
sleep 2s
125+
sleep 2
126126
docker-compose -f network1.yml up -d
127127
echo "> [Chain 2]"
128128
./1_prepare-genesis.sh 2
129129
[ $? -eq 0 ] || { echo >&2 "ERR AIO: Operation failed (genesis)"; exit 1; }
130-
sleep 2s
130+
sleep 2
131131
./2_build-docker-image.sh 2
132132
[ $? -eq 0 ] || { echo >&2 "ERR AIO: Operation failed (build docker image)"; exit 1; }
133-
sleep 2s
133+
sleep 2
134134
docker-compose -f network2.yml up -d
135-
sleep 20s
135+
sleep 20
136136

137137
cd "$AIO_CUR_DIR"
138138
cd "$AIO_DIR_HERMES"

big-dipper-as-block-explorer/1_install-bdjuno.sh

+6-6
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ PG_VOL_NAME="bdjdb$CHAIN_NO"
4343
}
4444

4545
echo 'Remove existing docker container & volumes'
46-
sleep 3s
46+
sleep 3
4747
docker rm -f $PG_CON_NAME
4848
docker volume rm -f $PG_VOL_NAME
4949

@@ -60,7 +60,7 @@ docker run \
6060
[ $? -eq 0 ] || { echo >&2 "ERR: Failed to create a PostgreSQL container"; }
6161

6262
echo 'Waiting DB up'
63-
sleep 20s
63+
sleep 20
6464

6565
echo "- Creating database $BD_PG_DB"
6666
PGPASSWORD=$BD_CFG_PG_USR_PASS psql -h 127.0.0.1 -p $PG_PORT -d postgres -U postgres -c "CREATE DATABASE $BD_PG_DB;"
@@ -80,26 +80,26 @@ if [ -d "./$BD_SOURCE_DIR" ]; then
8080
CHK_RES_1="$(git --git-dir "./$BD_SOURCE_DIR"/.git --work-tree "./$BD_SOURCE_DIR" config --get remote.origin.url)"
8181
if [ $? -ne 0 ] || [ -z "$CHK_RES_1" ]; then
8282
echo "WARN! Unable to check remote origin url of git repo at $BD_SOURCE_DIR"
83-
sleep 2s
83+
sleep 2
8484
elif [ "$CHK_RES_1" != "$BD_GIT_REPO" ]; then
8585
echo "WARN! Git repo Url does not match"
8686
echo "Expected: '$BD_GIT_REPO'"
8787
echo "Actual: '$CHK_RES_1'"
8888
echo "You should check it (script will continue execution after 10s)"
89-
sleep 10s
89+
sleep 10
9090
fi
9191
CHK_RES_2="$(git --git-dir "./$BD_SOURCE_DIR"/.git --work-tree "./$BD_SOURCE_DIR" rev-parse --abbrev-ref HEAD)"
9292
if [ $? -ne 0 ] || [ -z "$CHK_RES_2" ]; then
9393
echo "WARN! Unable to check branch of git repo at $BD_SOURCE_DIR"
94-
sleep 2s
94+
sleep 2
9595
elif [ "$CHK_RES_2" = "HEAD" ]; then
9696
echo "WARN! Can not check branch"
9797
elif [ "$CHK_RES_2" != "$BD_GIT_BRANCH" ]; then
9898
echo "WARN! Git Branch does not match"
9999
echo "Expected: '$BD_GIT_BRANCH'"
100100
echo "Actual: '$CHK_RES_2'"
101101
echo "You should check it (script will continue execution after 10s)"
102-
sleep 10s
102+
sleep 10
103103
fi
104104
else
105105
echo "Downloading bdjuno source code from branch $BD_GIT_BRANCH"

big-dipper-as-block-explorer/3_install-hasura.sh

+2-2
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ BD_HASURA_CON_NAME="bdjhasura$CHAIN_NO"
4545

4646
echo 'Remove existing containers'
4747
docker rm -f $BD_HASURA_CON_NAME
48-
sleep 1s
48+
sleep 1
4949

5050
echo 'Preparing DB'
5151
echo 'Dropping old data if exists'
@@ -80,7 +80,7 @@ docker run \
8080
hasura/graphql-engine:v2.7.0
8181

8282
echo 'Wait hasura up'
83-
sleep 3s
83+
sleep 3
8484

8585
echo 'Applying Hasura metadata'
8686

big-dipper-as-block-explorer/4_install-front-end.sh

+4-4
Original file line numberDiff line numberDiff line change
@@ -46,26 +46,26 @@ if [ -d "$BD2_SOURCE_DIR" ]; then
4646
CHK_RES_1="$(git --git-dir "./$BD2_SOURCE_DIR"/.git --work-tree "./$BD2_SOURCE_DIR" config --get remote.origin.url)"
4747
if [ $? -ne 0 ] || [ -z "$CHK_RES_1" ]; then
4848
echo "WARN! Unable to check remote origin url of git repo at $BD2_SOURCE_DIR"
49-
sleep 2s
49+
sleep 2
5050
elif [ "$CHK_RES_1" != "$BD2_GIT_REPO" ]; then
5151
echo "WARN! Git repo Url does not match"
5252
echo "Expected: '$BD2_GIT_REPO'"
5353
echo "Actual: '$CHK_RES_1'"
5454
echo "You should check it (script will continue execution after 10s)"
55-
sleep 10s
55+
sleep 10
5656
fi
5757
CHK_RES_2="$(git --git-dir "./$BD2_SOURCE_DIR"/.git --work-tree "./$BD2_SOURCE_DIR" rev-parse --abbrev-ref HEAD)"
5858
if [ $? -ne 0 ] || [ -z "$CHK_RES_2" ]; then
5959
echo "WARN! Unable to check branch of git repo at $BD2_SOURCE_DIR"
60-
sleep 2s
60+
sleep 2
6161
elif [ "$CHK_RES_2" = "HEAD" ]; then
6262
echo "WARN! Can not check branch"
6363
elif [ "$CHK_RES_2" != "$BD2_BRANCH" ]; then
6464
echo "WARN! Git Branch does not match"
6565
echo "Expected: '$BD2_BRANCH'"
6666
echo "Actual: '$CHK_RES_2'"
6767
echo "You should check it (script will continue execution after 10s)"
68-
sleep 10s
68+
sleep 10
6969
fi
7070
else
7171
echo "Downloading Big Dipper 2.0 source code from branch $BD2_BRANCH"

blockchain-in-docker/2_build-docker-image.sh

+4-4
Original file line numberDiff line numberDiff line change
@@ -58,26 +58,26 @@ if [ -d "$SOURCE_CODE_DIR" ]; then
5858
CHK_RES_1="$(git --git-dir "./$SOURCE_CODE_DIR"/.git --work-tree "./$SOURCE_CODE_DIR" config --get remote.origin.url)"
5959
if [ $? -ne 0 ] || [ -z "$CHK_RES_1" ]; then
6060
echo "WARN! Unable to check remote origin url of git repo at $SOURCE_CODE_DIR"
61-
sleep 2s
61+
sleep 2
6262
elif [ "$CHK_RES_1" != "$GIT_REPO" ]; then
6363
echo "WARN! Git repo Url does not match"
6464
echo "Expected: '$GIT_REPO'"
6565
echo "Actual: '$CHK_RES_1'"
6666
echo "You should check it (script will continue execution after 10s)"
67-
sleep 10s
67+
sleep 10
6868
fi
6969
CHK_RES_2="$(git --git-dir "./$SOURCE_CODE_DIR"/.git --work-tree "./$SOURCE_CODE_DIR" rev-parse --abbrev-ref HEAD)"
7070
if [ $? -ne 0 ] || [ -z "$CHK_RES_2" ]; then
7171
echo "WARN! Unable to check branch of git repo at $SOURCE_CODE_DIR"
72-
sleep 2s
72+
sleep 2
7373
elif [ "$CHK_RES_2" = "HEAD" ]; then
7474
echo "WARN! Can not check branch"
7575
elif [ "$CHK_RES_2" != "$GIT_BRANCH" ]; then
7676
echo "WARN! Git Branch does not match"
7777
echo "Expected: '$GIT_BRANCH'"
7878
echo "Actual: '$CHK_RES_2'"
7979
echo "You should check it (script will continue execution after 10s)"
80-
sleep 10s
80+
sleep 10
8181
fi
8282
else
8383
echo "Downloading $CHAIN_NAME source code $GIT_BRANCH"

blockchain-in-docker/_make_binary.sh

+4-4
Original file line numberDiff line numberDiff line change
@@ -9,26 +9,26 @@ if [ -d "$SOURCE_CODE_DIR" ]; then
99
CHK_RES_1="$(git --git-dir "./$SOURCE_CODE_DIR"/.git --work-tree "./$SOURCE_CODE_DIR" config --get remote.origin.url)"
1010
if [ $? -ne 0 ] || [ -z "$CHK_RES_1" ]; then
1111
echo "WARN! Unable to check remote origin url of git repo at $SOURCE_CODE_DIR"
12-
sleep 2s
12+
sleep 2
1313
elif [ "$CHK_RES_1" != "$GIT_REPO" ]; then
1414
echo "WARN! Git repo Url does not match"
1515
echo "Expected: '$GIT_REPO'"
1616
echo "Actual: '$CHK_RES_1'"
1717
echo "You should check it (script will continue execution after 10s)"
18-
sleep 10s
18+
sleep 10
1919
fi
2020
CHK_RES_2="$(git --git-dir "./$SOURCE_CODE_DIR"/.git --work-tree "./$SOURCE_CODE_DIR" rev-parse --abbrev-ref HEAD)"
2121
if [ $? -ne 0 ] || [ -z "$CHK_RES_2" ]; then
2222
echo "WARN! Unable to check branch of git repo at $SOURCE_CODE_DIR"
23-
sleep 2s
23+
sleep 2
2424
elif [ "$CHK_RES_2" = "HEAD" ]; then
2525
echo "WARN! Can not check branch"
2626
elif [ "$CHK_RES_2" != "$GIT_BRANCH" ]; then
2727
echo "WARN! Git Branch does not match"
2828
echo "Expected: '$GIT_BRANCH'"
2929
echo "Actual: '$CHK_RES_2'"
3030
echo "You should check it (script will continue execution after 10s)"
31-
sleep 10s
31+
sleep 10
3232
fi
3333
else
3434
echo "Downloading $CHAIN_NAME source code $GIT_BRANCH"

hermes-as-ibc-relayer/_make_binary.sh

+5-5
Original file line numberDiff line numberDiff line change
@@ -8,26 +8,26 @@ if [ -d "$HERMES_SOURCE_DIR" ]; then
88
CHK_RES_1="$(git --git-dir "./$HERMES_SOURCE_DIR"/.git --work-tree "./$HERMES_SOURCE_DIR" config --get remote.origin.url)"
99
if [ $? -ne 0 ] || [ -z "$CHK_RES_1" ]; then
1010
echo "WARN! Unable to check remote origin url of git repo at $HERMES_SOURCE_DIR"
11-
sleep 2s
11+
sleep 2
1212
elif [ "$CHK_RES_1" != "$HERMES_GIT_REPO" ]; then
1313
echo "WARN! Git repo Url does not match"
1414
echo "Expected: '$HERMES_GIT_REPO'"
1515
echo "Actual: '$CHK_RES_1'"
1616
echo "You should check it (script will continue execution after 10s)"
17-
sleep 10s
17+
sleep 10
1818
fi
1919
CHK_RES_2="$(git --git-dir "./$HERMES_SOURCE_DIR"/.git --work-tree "./$HERMES_SOURCE_DIR" rev-parse --abbrev-ref HEAD)"
2020
if [ $? -ne 0 ] || [ -z "$CHK_RES_2" ]; then
2121
echo "WARN! Unable to check branch of git repo at $HERMES_SOURCE_DIR"
22-
sleep 2s
22+
sleep 2
2323
elif [ "$CHK_RES_2" = "HEAD" ]; then
2424
echo "WARN! Can not check branch"
2525
elif [ "$CHK_RES_2" != "$HERMES_GIT_REPO_BRANCH" ]; then
2626
echo "WARN! Git Branch does not match"
2727
echo "Expected: '$HERMES_GIT_REPO_BRANCH'"
2828
echo "Actual: '$CHK_RES_2'"
2929
echo "You should check it (script will continue execution after 10s)"
30-
sleep 10s
30+
sleep 10
3131
fi
3232
else
3333
echo "Downloading Hermes source code $HERMES_GIT_REPO_BRANCH"
@@ -42,7 +42,7 @@ fi
4242
CUR_DIR=$(pwd)
4343
cd "$HERMES_SOURCE_DIR"
4444
echo "Compiling $HERMES_BINARY. If this is the first time you compile, it will take time, you can enjoy a cup of coffee and comeback later"
45-
sleep 3s
45+
sleep 3
4646
cargo build --release --bin $HERMES_BINARY
4747
[ $? -eq 0 ] || { echo >&2 "ERR: Failed to compile Hermes"; exit 1; }
4848
cd "$CUR_DIR"

hermes-as-ibc-relayer/create-relayer.sh

+10-10
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ export BINARY=$(pwd)'/'$HERMES_SOURCE_DIR'/target/release/'$HERMES_BINARY
5656
[ $? -eq 0 ] || { echo >&2 "ERR: Failed to check & build $HERMES_BINARY binary at $BINARY"; }
5757

5858
echo 'You can custom config by editing keys with prefix [HERMES_CFG_CHAIN_*] in [env.sh] file'
59-
sleep 3s
59+
sleep 3
6060

6161
echo "Chain ID: $HERMES_CFG_CHAIN_1_ID and $HERMES_CFG_CHAIN_2_ID"
6262
echo "Chain 1:"
@@ -71,7 +71,7 @@ echo "- gRPC: $HERMES_CFG_CHAIN_2_GRPC_ADDR"
7171
echo "- Account prefix: $HERMES_CFG_CHAIN_2_ACCOUNT_PREFIX"
7272
echo "- Relayer tx broadcast account key name: $HERMES_CFG_CHAIN_2_KEY_NAME"
7373
echo "- Gas price denom: $HERMES_CFG_CHAIN_2_GAS_PRICE_DENOM_SYMBOL"
74-
sleep 3s
74+
sleep 3
7575

7676
if [ $CHAIN_1_COINTYPE -eq 60 ] || [ "$CHAIN_1_TYPE" = "evmos" ]; then
7777
GAS_PRICE_1="$(bc <<< "20 * 10 ^ ($HERMES_CFG_CHAIN_1_DENOM_EXPONENT/2)")"
@@ -214,10 +214,10 @@ echo ' > Connection 1 to 2: '$CONN_1_TO_2
214214

215215
CONN_2_TO_1="$CONN_1_TO_2"
216216

217-
sleep 5s
217+
sleep 5
218218
echo ' + Testing connection 1'
219219
$BINARY --config $CONFIG_TOML query connection end --chain $HERMES_CFG_CHAIN_1_ID --connection $CONN_1_TO_2 | grep 'Open'
220-
sleep 2s
220+
sleep 2
221221

222222
echo '- Creating channel'
223223

@@ -256,30 +256,30 @@ echo "- Init for $HERMES_CFG_CHAIN_1_GAS_PRICE_DENOM_SYMBOL on $HERMES_CFG_CHAIN
256256
echo ' + FT-Transfer from '$HERMES_CFG_CHAIN_1_ID' to '$HERMES_CFG_CHAIN_2_ID
257257
$BINARY --config $CONFIG_TOML tx ft-transfer --dst-chain $HERMES_CFG_CHAIN_2_ID --src-chain $HERMES_CFG_CHAIN_1_ID --src-port transfer --src-channel $CHAN_1_TO_2 --timeout-seconds 1000 --amount 1000 --denom $HERMES_CFG_CHAIN_1_GAS_PRICE_DENOM_SYMBOL
258258
EXIT_CODE=$?
259-
sleep 2s
259+
sleep 2
260260
[ $EXIT_CODE -eq 0 ] || { echo >&2 "ERR: Operation failed (ft-transfer)"; exit 1; }
261261

262262
$BINARY --config $CONFIG_TOML tx packet-recv --dst-chain $HERMES_CFG_CHAIN_2_ID --src-chain $HERMES_CFG_CHAIN_1_ID --src-port transfer --src-channel $CHAN_1_TO_2
263-
sleep 2s
263+
sleep 2
264264
[ $EXIT_CODE -eq 0 ] || { echo >&2 "ERR: Operation failed (packet-recv)"; exit 1; }
265265

266266
echo "- Init for $HERMES_CFG_CHAIN_2_GAS_PRICE_DENOM_SYMBOL on $HERMES_CFG_CHAIN_1_ID"
267267
echo ' + FT-Transfer from '$HERMES_CFG_CHAIN_2_ID' to '$HERMES_CFG_CHAIN_1_ID
268268
$BINARY --config $CONFIG_TOML tx ft-transfer --dst-chain $HERMES_CFG_CHAIN_1_ID --src-chain $HERMES_CFG_CHAIN_2_ID --src-port transfer --src-channel $CHAN_1_TO_2 --timeout-seconds 1000 --amount 1000 --denom $HERMES_CFG_CHAIN_2_GAS_PRICE_DENOM_SYMBOL
269269
EXIT_CODE=$?
270-
sleep 2s
270+
sleep 2
271271
[ $EXIT_CODE -eq 0 ] || { echo >&2 "ERR: Operation failed (ft-transfer)"; exit 1; }
272272

273273
$BINARY --config $CONFIG_TOML tx packet-recv --dst-chain $HERMES_CFG_CHAIN_1_ID --src-chain $HERMES_CFG_CHAIN_2_ID --src-port transfer --src-channel $CHAN_2_TO_1
274-
sleep 2s
274+
sleep 2
275275
[ $EXIT_CODE -eq 0 ] || { echo >&2 "ERR: Operation failed (packet-recv)"; exit 1; }
276276

277277
$BINARY --config $CONFIG_TOML tx packet-ack --dst-chain $HERMES_CFG_CHAIN_2_ID --src-chain $HERMES_CFG_CHAIN_1_ID --src-port transfer --src-channel $CHAN_1_TO_2
278-
sleep 2s
278+
sleep 2
279279
[ $EXIT_CODE -eq 0 ] || { echo >&2 "ERR: Operation failed (packet-ack)"; exit 1; }
280280

281281
$BINARY --config $CONFIG_TOML tx packet-ack --dst-chain $HERMES_CFG_CHAIN_1_ID --src-chain $HERMES_CFG_CHAIN_2_ID --src-port transfer --src-channel $CHAN_2_TO_1
282-
sleep 2s
282+
sleep 2
283283
[ $EXIT_CODE -eq 0 ] || { echo >&2 "ERR: Operation failed (packet-ack)"; exit 1; }
284284

285285
echo 'Information summary'

0 commit comments

Comments
 (0)