This repository was archived by the owner on Sep 19, 2021. It is now read-only.
File tree 4 files changed +18
-18
lines changed
4 files changed +18
-18
lines changed Original file line number Diff line number Diff line change 17
17
HOST=" $1 "
18
18
PORT=" $2 "
19
19
20
- if [[ " $HOST " == " " || " $PORT " == " " ]] ; then
20
+ if [[ " ${ HOST} " == " " || " ${ PORT} " == " " ]] ; then
21
21
echo ' usage: <HOST> <PORT>'
22
22
exit 1
23
23
fi
24
24
25
25
cd ' ./bin'
26
- java codeu.chat.ClientMain " $HOST @ $ PORT"
26
+ java codeu.chat.ClientMain " ${ HOST} @ ${ PORT} "
Original file line number Diff line number Diff line change 17
17
PORT=" $1 "
18
18
TEAM_FILE=" $2 "
19
19
20
- if [[ " $PORT " == " " || " $TEAM_FILE " == " " ]] ; then
20
+ if [[ " ${ PORT} " == " " || " ${ TEAM_FILE} " == " " ]] ; then
21
21
echo ' usage: <PORT> <TEAM FILE>'
22
22
exit 1
23
23
fi
24
24
25
- if [ ! -f " $TEAM_FILE " ] ; then
26
- echo " No file at $TEAM_FILE "
25
+ if [ ! -f " ${ TEAM_FILE} " ] ; then
26
+ echo " No file at ${ TEAM_FILE} "
27
27
exit 1
28
28
fi
29
29
30
30
cd ' ./bin'
31
- java codeu.chat.RelayMain " $PORT " " $TEAM_FILE "
31
+ java codeu.chat.RelayMain " ${ PORT} " " ${ TEAM_FILE} "
Original file line number Diff line number Diff line change @@ -20,7 +20,7 @@ PORT="$3"
20
20
PERSISTENT_DIR=" $4 "
21
21
RELAY_ADDRESS=" $5 "
22
22
23
- if [[ " $TEAM_ID " == " " || " $TEAM_SECRET " == " " || " $PORT " == " " || " $PERSISTENT_DIR " == " " ]] ; then
23
+ if [[ " ${ TEAM_ID} " == " " || " ${ TEAM_SECRET} " == " " || " ${ PORT} " == " " || " ${ PERSISTENT_DIR} " == " " ]] ; then
24
24
echo ' usage: <TEAM ID> <TEAM SECRET> <PORT> <PERSISTENT> [RELAY ADDRESS]'
25
25
echo ' '
26
26
echo ' TEAM ID : The id registered with the relay server. If you are'
41
41
42
42
43
43
cd ' ./bin'
44
- if [ " $RELAY_ADDRESS " == " " ] ; then
44
+ if [ " ${ RELAY_ADDRESS} " == " " ] ; then
45
45
java codeu.chat.ServerMain \
46
- " $TEAM_ID " \
47
- " $TEAM_SECRET " \
48
- " $PORT " \
49
- " $PERSISTENT_DIR "
46
+ " ${ TEAM_ID} " \
47
+ " ${ TEAM_SECRET} " \
48
+ " ${ PORT} " \
49
+ " ${ PERSISTENT_DIR} "
50
50
else
51
51
java codeu.chat.ServerMain \
52
- " $TEAM_ID " \
53
- " $TEAM_SECRET " \
54
- " $PORT " \
55
- " $PERSISTENT_DIR " \
56
- " $RELAY_ADDRESS "
52
+ " ${ TEAM_ID} " \
53
+ " ${ TEAM_SECRET} " \
54
+ " ${ PORT} " \
55
+ " ${ PERSISTENT_DIR} " \
56
+ " ${ RELAY_ADDRESS} "
57
57
fi
Original file line number Diff line number Diff line change @@ -18,4 +18,4 @@ LOCAL_MACHINE="localhost@2007"
18
18
19
19
cd ' ./bin'
20
20
21
- java codeu.chat.SimpleGuiClientMain " $LOCAL_MACHINE "
21
+ java codeu.chat.SimpleGuiClientMain " ${ LOCAL_MACHINE} "
You can’t perform that action at this time.
0 commit comments