Skip to content

Commit

Permalink
Slight groupping fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
meeDamian committed Apr 6, 2020
1 parent 1d6696e commit 22d0bed
Showing 1 changed file with 6 additions and 7 deletions.
13 changes: 6 additions & 7 deletions entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,6 @@ set -e

PKG="meeDamian/[email protected]"

echo "::group::Process inputs"

#
## Input verification
#
Expand Down Expand Up @@ -85,7 +83,6 @@ if [ -n "$release_id" ] && [ "$INPUT_ALLOW_OVERRIDE" != "true" ]; then
exit 1
fi

echo "::endgroup::"
echo "::group::Create Release"

TMP="$(mktemp -d)"
Expand Down Expand Up @@ -154,12 +151,13 @@ echo "::endgroup::"
#
## Handle, and prepare assets
#
echo "::group::Upload Assets"

if [ -z "$INPUT_FILES" ]; then
>&2 echo "No assets to upload. All done."
exit 0
fi

echo "::group::Upload Assets"

assets="$HOME/assets"
mkdir -p "$assets/"
Expand Down Expand Up @@ -260,13 +258,14 @@ for asset in "$assets"/*; do
done

echo "::endgroup::"
echo "::group::Complete Release"

if [ -n "$INPUT_DRAFT" ]; then
>&2 echo "Draft status already correct. All done."
exit 0
fi

echo "::group::Complete Release"

# Publish Release
# docs ref: https://developer.github.com/v3/repos/releases/#edit-a-release
status_code="$(curl -sS -X PATCH -d '{"draft": false}' \
Expand All @@ -282,6 +281,6 @@ if [ "$status_code" != "200" ]; then
exit 1
fi

>&2 echo "All done."

echo "::endgroup::"

>&2 echo "All done."

0 comments on commit 22d0bed

Please sign in to comment.