Skip to content

Commit

Permalink
更新 unpack.sh
Browse files Browse the repository at this point in the history
  • Loading branch information
zjw2017 committed Jul 21, 2024
1 parent 7abecca commit bea27b4
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions unpack.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,12 @@
# shellcheck disable=SC2034

# 适用于出厂安卓13的机型
unpack_partiton="system odm system_ext product vendor mi_ext system_dlkm vendor_dlkm"
# unpack_partiton="system odm system_ext product vendor mi_ext system_dlkm vendor_dlkm"
# 适用于升级到安卓13的机型
# unpack_partiton="system odm system_ext product vendor mi_ext"
# 适用于没有官方安卓13的机型
# unpack_partiton="system odm system_ext product vendor"
unpack_partiton="system system_ext"

mkdir -p "$GITHUB_WORKSPACE"/get_files

Expand Down Expand Up @@ -52,9 +53,9 @@ get_system_files() {
fi
path=${source%/*}
mkdir -p "$GITHUB_WORKSPACE"/get_files"$path"
if [ -f "$source" ]; then
if [ -f "$GITHUB_WORKSPACE"/"$device""$source" ]; then
cp "$GITHUB_WORKSPACE"/"$device""$source" "$GITHUB_WORKSPACE"/get_files"$path"
elif [ -d "$source" ]; then
elif [ -d "$GITHUB_WORKSPACE"/"$device""$source" ]; then
cp -r "$GITHUB_WORKSPACE"/"$device""$source" "$GITHUB_WORKSPACE"/get_files"$path"
else
echo "$source 不存在"
Expand All @@ -65,7 +66,7 @@ extract_files() {
cp "$GITHUB_WORKSPACE"/info.txt "$GITHUB_WORKSPACE"/get_files
# get_device_features
# get_prop_files
get_system_files "/product/priv-app/MiuiHome"
get_system_files "/system/app/PowerKeeper"
get_system_files "/system_ext/priv-app/MiuiSystemUI/MiuiSystemUI.apk"
# get_files_config
}

0 comments on commit bea27b4

Please sign in to comment.