developer: Fix build.sh to inline EXECUTABLE_DELTA constant

This commit is contained in:
Ethan P 2020-04-30 21:57:54 -07:00
parent 29fb251348
commit 275c66b213
No known key found for this signature in database
GPG Key ID: 6963FD04F6CF35EA

View File

@ -274,14 +274,13 @@ pp_consolidate__do() {
} }
# Inlines constants: # Inlines constants:
# EXECUTABLE_BAT # EXECUTABLE_*
# EXECUTABLE_GIT
# PROGRAM_* # PROGRAM_*
pp_inline_constants() { pp_inline_constants() {
local constants=("EXECUTABLE_BAT" "EXECUTABLE_GIT" "PROGRAM") local constants=("PROGRAM")
# Determine the PROGRAM_ constants. # Determine the PROGRAM_ constants.
local nf_constants="$( ( set -o posix ; set) | grep '^PROGRAM_' | cut -d'=' -f1)" local nf_constants="$( ( set -o posix ; set) | grep '^\(PROGRAM_\|EXECUTABLE_\)' | cut -d'=' -f1)"
local line local line
while read -r line; do while read -r line; do
constants+=("$line") constants+=("$line")
@ -301,6 +300,7 @@ pp_inline_constants() {
sed "${constants_pattern}" sed "${constants_pattern}"
} }
# Strips comments from a Bash source file. # Strips comments from a Bash source file.
pp_strip_comments() { pp_strip_comments() {
sed '/^[[:space:]]*#.*$/d' sed '/^[[:space:]]*#.*$/d'