mirror of
https://github.com/eth-p/bat-extras.git
synced 2024-12-12 17:20:40 +01:00
release.sh: Stop packages from inlining alternate executable names
This commit is contained in:
parent
1f7d9c3fcc
commit
3c5651bde9
15
release.sh
15
release.sh
@ -60,7 +60,7 @@ fi
|
||||
|
||||
# Generate the new bin files.
|
||||
printc "%{YELLOW}Building scripts...%{CLEAR}\n"
|
||||
"$HERE/build.sh" --minify=all --alternate-executable='bat' &>/dev/null || {
|
||||
"$HERE/build.sh" --minify=all --alternate-executable='bat' --no-inline &>/dev/null || {
|
||||
printc "%{RED}FAILED TO BUILD SCRIPTS.%{CLEAR}\n"
|
||||
printc "%{RED}CAN NOT PROCEED WITH RELEASE.%{CLEAR}\n"
|
||||
exit 1
|
||||
@ -70,9 +70,13 @@ printc "%{YELLOW}Building scripts...%{CLEAR}\n"
|
||||
# Build package.
|
||||
|
||||
printc "%{YELLOW}Packaging artifacts...%{CLEAR}\n"
|
||||
zip -r "$OPT_ARTIFACT" \
|
||||
"$OPT_BIN_DIR" \
|
||||
"$OPT_DOC_DIR"
|
||||
(
|
||||
rm "$OPT_ARTIFACT"
|
||||
cd "$(dirname "$OPT_BIN_DIR")"
|
||||
zip -r "$OPT_ARTIFACT" "$(basename "$OPT_BIN_DIR")"
|
||||
cd "$(dirname "$OPT_DOC_DIR")"
|
||||
zip -ru "$OPT_ARTIFACT" "$(basename "$OPT_DOC_DIR")"
|
||||
)
|
||||
|
||||
printc "%{YELLOW}Package created as %{BLUE}%s%{YELLOW}.%{CLEAR}\n" "$OPT_ARTIFACT"
|
||||
|
||||
@ -97,7 +101,6 @@ case "$DATE_DAY" in
|
||||
esac
|
||||
DATE_STR="$(date +'%B') ${DATE_DAY}${DATE_SUFFIX}, $(date +'%Y')"
|
||||
|
||||
|
||||
# Get the script names.
|
||||
script_links=()
|
||||
script_names=()
|
||||
@ -111,7 +114,6 @@ script_pattern="$(printf 's/\\(%s\\)/`\\1`/;' "${script_names[@]}")"
|
||||
SCRIPTS="$(printf "%s, " "${script_links[@]:0:$((${#script_links[@]} - 1))}")"
|
||||
SCRIPTS="${SCRIPTS}and ${script_links[$((${#script_links[@]} - 1))]}"
|
||||
|
||||
|
||||
# Get the changelog.
|
||||
CHANGELOG_DEV=''
|
||||
CHANGELOG=''
|
||||
@ -151,7 +153,6 @@ fi
|
||||
CHANGELOG="$(sed "$script_pattern" <<< "$CHANGELOG")"
|
||||
CHANGELOG_DEV="$(sed "$script_pattern" <<< "$CHANGELOG_DEV")"
|
||||
|
||||
|
||||
# Print the template.
|
||||
sed '/\\$/{N;s/\\\n//;s/\n//p;}' <<- EOF
|
||||
This contains the latest versions of $SCRIPTS as of commit [$(git rev-parse --short HEAD)]($COMMIT_URL) (${DATE_STR}).
|
||||
|
Loading…
Reference in New Issue
Block a user