瀏覽代碼

Quote variables and backticks

Otherwise the script fails with spaces or asterisks in the directory path.
Jan Verbeek 8 年之前
父節點
當前提交
42debcfe3c
共有 1 個檔案被更改,包括 1 行新增1 行删除
  1. 1
    1
      manage.sh

+ 1
- 1
manage.sh 查看文件

@@ -1,6 +1,6 @@
1 1
 #!/bin/sh
2 2
 
3
-BASE_DIR=$(dirname `readlink -f $0`)
3
+BASE_DIR=$(dirname "`readlink -f "$0"`")
4 4
 PYTHONPATH=$BASE_DIR
5 5
 SEARX_DIR="$BASE_DIR/searx"
6 6
 ACTION=$1