aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
authorEgor Tensin <Egor.Tensin@gmail.com>2017-09-02 22:16:19 +0300
committerEgor Tensin <Egor.Tensin@gmail.com>2017-09-02 22:16:19 +0300
commit1a3aae1e065beda7d0cb14c1536dd52132e57fa2 (patch)
treea613ecdf8679afc7093de7f548e12b41e5b38e42
parentadd .ghci and .stack/config.yaml (diff)
downloadlinux-home-1a3aae1e065beda7d0cb14c1536dd52132e57fa2.tar.gz
linux-home-1a3aae1e065beda7d0cb14c1536dd52132e57fa2.zip
add fix_permissions.sh
-rw-r--r--README.md9
-rwxr-xr-xfix_permissions.sh7
2 files changed, 15 insertions, 1 deletions
diff --git a/README.md b/README.md
index 5194043..8a758ff 100644
--- a/README.md
+++ b/README.md
@@ -18,9 +18,16 @@ Using [config-links]:
> ../config-links/update.sh
...
+Issues
+------
+
+Some utilities (notably, GHC) may not work if its configuration files are
+group-writable.
+To fix this, run `chmod g-w` for every file & directory in this repository (you
+can do this using the supplied fix_permissions.sh script).
+
License
-------
-
Distributed under the MIT License.
See [LICENSE.txt] for details.
diff --git a/fix_permissions.sh b/fix_permissions.sh
new file mode 100755
index 0000000..65974b9
--- /dev/null
+++ b/fix_permissions.sh
@@ -0,0 +1,7 @@
+#!/usr/bin/env bash
+
+set -o errexit -o nounset -o pipefail
+
+script_dir="$( dirname -- "${BASH_SOURCE[0]}" )"
+script_dir="$( cd -- "$script_dir" && pwd )"
+find "$script_dir" -mindepth 1 -path ./.git -prune -o -exec chmod g-w {} +