Radish alpha
h
Radicle Heartwood Protocol & Stack
Radicle
Git (anonymous pull)
Log in to clone via SSH
REVIEW: Make variables readonly
Lorenz Leutgeb committed 24 days ago
commit 234fe66f0a9a04bca22f66d61fc9fe9ec5a713f6
parent 371e66353ff7a7779a9dc7cb2587e617b520a6fb
1 file changed +3 -3
modified scripts/git-hook-template.sh
@@ -1,7 +1,7 @@
#! /usr/bin/env bash
set -e

-
HOOK_NAME=$(basename "$0")
+
readonly HOOK_NAME=$(basename "$0")

if ! [[ "$HOOK_NAME" =~ ^(pre-(commit|push)|post-checkout)$ ]]
then
@@ -9,8 +9,8 @@ then
    exit 1
fi

-
SENSITIVE_FILES=("justfile" "build.rs" "rust-toolchain.toml")
-
BASE_BRANCH="master"
+
readonly SENSITIVE_FILES=("justfile" "build.rs" "rust-toolchain.toml")
+
readonly BASE_BRANCH="master"

# Check which files were modified compared to the base branch.
mapfile -t CHANGED_FILES < <(comm -12 \