Skip to content

Commit

Permalink
feat: export OHOS_NDK_HOME to env by default
Browse files Browse the repository at this point in the history
Signed-off-by: richerfu <[email protected]>
Signed-off-by: Jonathan Schwender <[email protected]>
  • Loading branch information
richerfu authored and jschwe committed Oct 6, 2024
1 parent b5cc055 commit 6bcb988
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
1 change: 0 additions & 1 deletion action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -66,4 +66,3 @@ runs:
INPUT_FIXUP_PATH: ${{ inputs.fixup-path }}
INPUT_MIRROR: "${{ inputs.mirror }}"
GH_TOKEN: "${{ github.token }}"

3 changes: 3 additions & 0 deletions install_ohos_sdk.sh
Original file line number Diff line number Diff line change
Expand Up @@ -106,15 +106,18 @@ done
rm ./*.zip

if [ "${INPUT_FIXUP_PATH}" = "true" ]; then
OHOS_NDK_HOME="${OHOS_BASE_SDK_HOME}/${API_VERSION}"
OHOS_SDK_NATIVE="${OHOS_BASE_SDK_HOME}/${API_VERSION}/native"
else
OHOS_NDK_HOME="${OHOS_BASE_SDK_HOME}"
OHOS_SDK_NATIVE="${OHOS_BASE_SDK_HOME}/native"
fi
cd "${OHOS_SDK_NATIVE}"
SDK_VERSION="$(jq -r .version < oh-uni-package.json )"
API_VERSION="$(jq -r .apiVersion < oh-uni-package.json )"
echo "OHOS_BASE_SDK_HOME=${OHOS_BASE_SDK_HOME}" >> "$GITHUB_ENV"
echo "ohos-base-sdk-home=${OHOS_BASE_SDK_HOME}" >> "$GITHUB_OUTPUT"
echo "OHOS_NDK_HOME=${OHOS_NDK_HOME}" >> "$GITHUB_ENV"
echo "OHOS_SDK_NATIVE=${OHOS_SDK_NATIVE}" >> "$GITHUB_ENV"
echo "ohos_sdk_native=${OHOS_SDK_NATIVE}" >> "$GITHUB_OUTPUT"
echo "sdk-version=${SDK_VERSION}" >> "$GITHUB_OUTPUT"
Expand Down

0 comments on commit 6bcb988

Please sign in to comment.