瀏覽代碼

fix bashisms in install.sh

tags/v1.1.0-rc1
Shivaram Lingamneni 5 年之前
父節點
當前提交
8fa70e2c45
共有 1 個文件被更改,包括 7 次插入7 次删除
  1. 7
    7
      install.sh

+ 7
- 7
install.sh 查看文件

@@ -5,8 +5,8 @@ set -e
5 5
 if [ -z "$GOPATH" ]; then
6 6
 	echo Error: \$GOPATH is unset
7 7
 	echo See https://golang.org/doc/code.html for details, or try these steps:
8
-	echo -e "\tmkdir -p ~/go"
9
-	echo -e "\texport GOPATH=~/go"
8
+	printf "\tmkdir -p ~/go\n"
9
+	printf "\texport GOPATH=~/go\n"
10 10
 	exit 1
11 11
 fi
12 12
 
@@ -17,12 +17,12 @@ if [ "$PWD" != "$EXPECTED_DIR" ] ; then
17 17
 	echo "Expected: $EXPECTED_DIR"
18 18
 	echo "Actual:   $PWD"
19 19
 	echo See https://golang.org/doc/code.html for details, or try these steps:
20
-	echo -e "\tmkdir -p ${GOPATH}/src/github.com/oragono"
21
-	echo -e "\tcd ${GOPATH}/src/github.com/oragono"
22
-	echo -e "\tmv $PWD oragono"
23
-	echo -e "\tcd oragono"
20
+	printf "\tmkdir -p %s/src/github.com/oragono\n" "$GOPATH"
21
+	printf "\tcd %s/src/github.com/oragono\n" "$GOPATH"
22
+	printf "\tmv %s oragono\n" "$PWD"
23
+	printf "\tcd oragono\n"
24 24
 	exit 1
25 25
 fi
26 26
 
27 27
 go install -v
28
-echo successfully installed as ${GOPATH}/bin/oragono
28
+echo successfully installed as "${GOPATH}/bin/oragono"

Loading…
取消
儲存