... |
... |
@@ -27,7 +27,8 @@ function mk_dir {
|
27 |
27 |
# directives.
|
28 |
28 |
invoked_name="$(basename "${0}")"
|
29 |
29 |
|
30 |
|
-# By default, invoke "firefox":
|
|
30 |
+# By default, invoke "proot" and "firefox":
|
|
31 |
+proot_path="$(which 'proot')"
|
31 |
32 |
browser_path='firefox'
|
32 |
33 |
|
33 |
34 |
# Base directory for our crap
|
... |
... |
@@ -105,10 +106,11 @@ generic_config_path="${HOME}/.config/browser-wrapper/main.conf"
|
105 |
106 |
specific_config_path="${HOME}/.config/browser-wrapper/${invoked_name}.conf"
|
106 |
107 |
[ -f "${specific_config_path}" ] && source "${specific_config_path}"
|
107 |
108 |
|
108 |
|
-# Let users override this again through an environment variable:
|
|
109 |
+# Let users override some things through environment variables:
|
|
110 |
+[ -n "${BW_PROOT_PATH}" ] && proot_path="${BW_PROOT_PATH}"
|
109 |
111 |
[ -n "${BW_BROWSER_PATH}" ] && browser_path="${BW_BROWSER_PATH}"
|
110 |
112 |
|
111 |
|
-if [ -x "$(which proot)" ]; then
|
|
113 |
+if [ -x "${proot_path}" ]; then
|
112 |
114 |
echo "proot is present and will be used to mask some directories"
|
113 |
115 |
|
114 |
116 |
echo 'Tips:'
|
... |
... |
@@ -119,7 +121,7 @@ if [ -x "$(which proot)" ]; then
|
119 |
121 |
echo ' Do you need to download files?'
|
120 |
122 |
echo " They should end up in ${download_dir}"
|
121 |
123 |
|
122 |
|
- proot \
|
|
124 |
+ "${proot_path}" \
|
123 |
125 |
${pre_options} \
|
124 |
126 |
${slash_home_options} \
|
125 |
127 |
${home_options} \
|