mirror of
https://github.com/hackacad/bastille.git
synced 2026-02-02 21:06:02 +01:00
template: remove duplicate line
This commit is contained in:
@@ -70,7 +70,13 @@ parse_arg_value() {
|
||||
local arg="${1}"
|
||||
|
||||
# Parses the value after = and then escapes back/forward slashes and single quotes in it. -- cwells
|
||||
eval echo "${arg}" | sed -E 's/[^=]+=?//' | sed -e 's/\\/\\\\/g' -e 's/\//\\\//g' -e 's/'\''/'\''\\'\'\''/g' -e 's/&/\\&/g' -e 's/"//g'
|
||||
eval echo "${arg}" | \
|
||||
sed -E 's/[^=]+=?//' | \
|
||||
sed -e 's/\\/\\\\/g' \
|
||||
-e 's/\//\\\//g' \
|
||||
-e 's/'\''/'\''\\'\'\''/g' \
|
||||
-e 's/&/\\&/g' \
|
||||
-e 's/"//g'
|
||||
}
|
||||
|
||||
get_arg_value() {
|
||||
@@ -116,7 +122,6 @@ render() {
|
||||
|
||||
if [ -d "${file_path}" ]; then # Recursively render every file in this directory. -- cwells
|
||||
echo "Rendering Directory: ${file_path}"
|
||||
find "${file_path}" \( -type d -name .git -prune \) -o -type f
|
||||
find "${file_path}" \( -type d -name .git -prune \) -o -type f -print0 | eval "xargs -0 sed -i '' ${ARG_REPLACEMENTS}"
|
||||
elif [ -f "${file_path}" ]; then
|
||||
echo "Rendering File: ${file_path}"
|
||||
|
||||
Reference in New Issue
Block a user