回答編集履歴
3
まだまだ修正
answer
CHANGED
@@ -2,7 +2,7 @@
|
|
2
2
|
readonly dst_Dir=/path/to/dst
|
3
3
|
|
4
4
|
if [[ $(wget --spider -nv "http://${HOSTNAME}/" 2>&1 | grep '200 OK') -eq 0 ]]; then
|
5
|
-
mkdir -p "{dst_Dir}" && wget -q -P "{dst_Dir}" "http://${HOSTNAME}/"
|
5
|
+
mkdir -p "${dst_Dir}" && wget -q -P "${dst_Dir}" "http://${HOSTNAME}/"
|
6
6
|
fi
|
7
7
|
|
8
8
|
ですかね。
|
2
文字修正
answer
CHANGED
@@ -2,7 +2,7 @@
|
|
2
2
|
readonly dst_Dir=/path/to/dst
|
3
3
|
|
4
4
|
if [[ $(wget --spider -nv "http://${HOSTNAME}/" 2>&1 | grep '200 OK') -eq 0 ]]; then
|
5
|
-
mkdir -p "{
|
5
|
+
mkdir -p "{dst_Dir}" && wget -q -P "{dst_Dir}" "http://${HOSTNAME}/"
|
6
6
|
fi
|
7
7
|
|
8
8
|
ですかね。
|
1
修正
answer
CHANGED
@@ -1,8 +1,8 @@
|
|
1
1
|
readonly HOSTNAME="dst_host_filename"
|
2
2
|
readonly dst_Dir=/path/to/dst
|
3
3
|
|
4
|
-
if [[ $(wget --spider -nv http://$HOSTNAME/ 2>&1 | grep '200 OK') -eq 0 ]]; then
|
4
|
+
if [[ $(wget --spider -nv "http://${HOSTNAME}/" 2>&1 | grep '200 OK') -eq 0 ]]; then
|
5
|
-
mkdir -p "{dst_Drr}" && wget -q -P "{dst_Drr}" http://$HOSTNAME/
|
5
|
+
mkdir -p "{dst_Drr}" && wget -q -P "{dst_Drr}" "http://${HOSTNAME}/"
|
6
6
|
fi
|
7
7
|
|
8
8
|
ですかね。
|