Skip to content

Commit

Permalink
chore(ci): replace cache check file
Browse files Browse the repository at this point in the history
Deprecated "set-output" command
Modify filename to build.gradle.kts
  • Loading branch information
wxyzh authored and Bambooin committed Apr 2, 2023
1 parent de7fdd3 commit 37a762a
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions script/cache-hash.sh
Expand Up @@ -5,11 +5,11 @@ MAGIC=magic.txt
echo auto generated contents >> $MAGIC

# fetch jni relative elements
grep ndkVersion app/build.gradle >> $MAGIC
grep ndkVersion app/build.gradle.kts >> $MAGIC

elments=("buildTypes" "externalNativeBuild" "splits")
for element in ${elments[@]}; do
awk "/$element/,/\}/" app/build.gradle >> $MAGIC
awk "/$element/,/\}/" app/build.gradle.kts >> $MAGIC
done

JNI_FILES="$MAGIC app/src/main/jni/cmake/* app/src/main/jni/librime_jni/* app/src/main/jni/CMakeLists.txt"
Expand All @@ -18,4 +18,4 @@ hash=$(git submodule status)
hash=$hash$($DIGEST_ALGORITHM $JNI_FILES)
hash=$(echo $hash | $DIGEST_ALGORITHM | cut -c-64)

echo "::set-output name=hash::$hash"
echo "{hash}={hash}" >> $GITHUB_OUTPUT

0 comments on commit 37a762a

Please sign in to comment.