Skip to content

Commit 9bd4808

Browse files
committed
fix(direnv): red was undefined
* added -u to prevent it regressing
1 parent 08d34a6 commit 9bd4808

File tree

2 files changed

+9
-2
lines changed

2 files changed

+9
-2
lines changed

.envrc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
# initialization (e.g. activating the venv) or giving recommendations on how to reach the desired state.
55
# It also sets useful environment variables.
66
# If you'd like to override or set any custom environment variables, this .envrc will read a .env file at the end.
7-
set -e
7+
set -eu
88

99
# Upgrading Mac can uninstall the Command Line Tools, thus, removing our access to git
1010
# The message talks about xcrun, however, we can use the lack of git as a way to know that we need this
@@ -21,7 +21,7 @@ SENTRY_ROOT="$(
2121
pwd -P
2222
)"
2323

24-
source "${SENTRY_ROOT}/scripts/lib.sh"
24+
source "${SENTRY_ROOT}/"scripts/lib.sh
2525

2626
# XXX: we can't trap bash EXIT, because it'll override direnv's finalizing routines.
2727
# consequently, using "exit" anywhere will skip this notice from showing.

scripts/lib.sh

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,13 @@ fi
1515

1616
venv_name=".venv"
1717

18+
# selected ansi colors
19+
bold="$(tput bold)"
20+
red="$(tput setaf 1)"
21+
green="$(tput setaf 2)"
22+
yellow="$(tput setaf 3)"
23+
reset="$(tput sgr0)"
24+
1825
# XDG paths' standardized defaults:
1926
# (see https://specifications.freedesktop.org/basedir-spec/basedir-spec-latest.html#variables )
2027
export XDG_DATA_HOME="${XDG_DATA_HOME:-$HOME/.local/share}"

0 commit comments

Comments
 (0)