Skip to content

Commit 8f79c4c

Browse files
authored
fix(install.sh): guard rm -rf with ${SKILLS_DIR:?} (shellcheck SC2115) (#72)
Defense-in-depth against an empty SKILLS_DIR expanding to a root-level path. Empty values are already rejected upstream; this makes it impossible by construction. One-char change, behavior otherwise identical.
1 parent 1d3e589 commit 8f79c4c

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

install.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ count=0
6969
for dir in "$SRC"/*/; do
7070
[ -f "${dir}SKILL.md" ] || continue
7171
name="$(basename "$dir")"
72-
rm -rf "${SKILLS_DIR}/${name}"
72+
rm -rf "${SKILLS_DIR:?}/${name}"
7373
cp -R "$dir" "${SKILLS_DIR}/${name}"
7474
count=$((count + 1))
7575
done

0 commit comments

Comments
 (0)