|
|
|
|
@ -43,35 +43,35 @@ runs:
@@ -43,35 +43,35 @@ runs:
|
|
|
|
|
release_valid_inputs=("Initial Release" "Redeploy" "Dry Run") |
|
|
|
|
if [[ ! "${release_valid_inputs[@]}" =~ "${{ inputs.release-type }}" ]]; then |
|
|
|
|
echo "[!] 'release-type' option only supports the following values: (${release_valid_inputs})" |
|
|
|
|
echo "::set-output name=step-failed::true" |
|
|
|
|
echo "step-failed=true" >> $GITHUB_OUTPUT |
|
|
|
|
fi |
|
|
|
|
|
|
|
|
|
project_type_valid_inputs=("ts" "dotnet" "xamarin") |
|
|
|
|
if [[ ! "${project_type_valid_inputs[@]}" =~ "${{ inputs.project-type }}" ]]; then |
|
|
|
|
echo "[!] 'project-type' option only supports the following values: (${project_type_valid_inputs})" |
|
|
|
|
echo "::set-output name=step-failed::true" |
|
|
|
|
echo "step-failed=true" >> $GITHUB_OUTPUT |
|
|
|
|
fi |
|
|
|
|
|
|
|
|
|
if [ ! -f "${{ inputs.file }}" ]; then |
|
|
|
|
echo "[!] The relative path '${{ inputs.file}}' doesn't exist" |
|
|
|
|
echo "::set-output name=step-failed::true" |
|
|
|
|
echo "step-failed=true" >> $GITHUB_OUTPUT |
|
|
|
|
fi |
|
|
|
|
|
|
|
|
|
monorepo_valid_inputs=("true" "false") |
|
|
|
|
if [[ ! "${monorepo_valid_inputs[@]}" =~ "${{ inputs.monorepo }}" ]]; then |
|
|
|
|
echo "[!] 'monorepo' option only supports the following values: (${monorepo_valid_inputs})" |
|
|
|
|
echo "::set-output name=step-failed::true" |
|
|
|
|
echo "step-failed=true" >> $GITHUB_OUTPUT |
|
|
|
|
fi |
|
|
|
|
|
|
|
|
|
if [ "${{ inputs.monorepo }}" == "true" ] && [ "${{ inputs.monorepo-project }}" == "" ]; then |
|
|
|
|
echo "[!] using the 'monorepo' option requires the use of 'monorepo-project'" |
|
|
|
|
echo "::set-output name=step-failed::true" |
|
|
|
|
echo "step-failed=true" >> $GITHUB_OUTPUT |
|
|
|
|
fi |
|
|
|
|
|
|
|
|
|
monorepo_project_valid_inputs=("" "browser" "cli" "desktop" "web") |
|
|
|
|
if [[ ! "${monorepo_project_valid_inputs[@]}" =~ "${{ inputs.monorepo-project }}" ]]; then |
|
|
|
|
echo "[!] 'monorepo-project' option only supports the following values: (${monorepo_project_valid_inputs})" |
|
|
|
|
echo "::set-output name=step-failed::true" |
|
|
|
|
echo "step-failed=true" >> $GITHUB_OUTPUT |
|
|
|
|
fi |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@ -91,7 +91,7 @@ runs:
@@ -91,7 +91,7 @@ runs:
|
|
|
|
|
version=$(sed -E -n '/^<manifest/s/^.*[ ]android:versionName="([^"]+)".*$/\1/p' ${{ inputs.file }} | tr -d '"') |
|
|
|
|
;; |
|
|
|
|
esac |
|
|
|
|
echo "::set-output name=version::$version" |
|
|
|
|
echo "version=$version" >> $GITHUB_OUTPUT |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
- name: Get current released version |
|
|
|
|
@ -117,7 +117,7 @@ runs:
@@ -117,7 +117,7 @@ runs:
|
|
|
|
|
else |
|
|
|
|
previous_release_version=${{ inputs.override-version }} |
|
|
|
|
fi |
|
|
|
|
echo "::set-output name=version::$previous_release_version" |
|
|
|
|
echo "version=$previous_release_version" >> $GITHUB_OUTPUT |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
- name: Check versions |
|
|
|
|
@ -129,7 +129,7 @@ runs:
@@ -129,7 +129,7 @@ runs:
|
|
|
|
|
if [ "$new_version" == "$current_version" ] && \ |
|
|
|
|
[ "${{ inputs.release-type }}" == "Initial Release" ]; then |
|
|
|
|
echo "[!] Already released $new_version. Please bump version to continue" |
|
|
|
|
echo "::set-output name=step-failed::true" |
|
|
|
|
echo "step-failed=true" >> $GITHUB_OUTPUT |
|
|
|
|
fi |
|
|
|
|
|
|
|
|
|
- name: Set status |
|
|
|
|
@ -144,8 +144,8 @@ runs:
@@ -144,8 +144,8 @@ runs:
|
|
|
|
|
echo $failed_statuses |
|
|
|
|
|
|
|
|
|
if [[ "${failed_statuses[@]}" =~ "true" ]]; then |
|
|
|
|
echo "::set-output name=status::fail" |
|
|
|
|
echo "status=fail" >> $GITHUB_OUTPUT |
|
|
|
|
exit 1 |
|
|
|
|
else |
|
|
|
|
echo "::set-output name=status::success" |
|
|
|
|
echo "status=success" >> $GITHUB_OUTPUT |
|
|
|
|
fi |
|
|
|
|
|