-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathcustomize_framework-res.sh
executable file
·46 lines (41 loc) · 1.25 KB
/
customize_framework-res.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
#!/bin/bash
#
# $1: dir for miui overlay framework-res
# $2: dir for target framework-res
#
if [ `basename $1` = "drawable-hdpi" -o `basename $1` = "drawable-xhdpi" ];then
restype=`basename $1`
for file in `find "$1"`
do
newfile=`basename $file`
newfile1=`echo $newfile | sed -e "s/^/zzzhtc_/"`
targetfile="$2/$restype/$newfile1"
if [ -f $targetfile ]
then
mkdir -p `dirname $targetfile`
echo "add miui res: $file"
echo " >> $targetfile"
cp $file $targetfile
fi
newfile1=`echo $newfile | sed -e "s/^/zzz_/"`
targetfile="$2/$restype/$newfile1"
if [ -f $targetfile ]
then
mkdir -p `dirname $targetfile`
echo "add miui res: $file"
echo " >> $targetfile"
cp $file $targetfile
fi
newfile1=`echo $newfile | sed -e "s/^/zzzz_/"`
targetfile="$2/$restype/$newfile1"
if [ -f $targetfile ]
then
mkdir -p `dirname $targetfile`
echo "add miui res: $file"
echo " >> $targetfile"
cp $file $targetfile
fi
done
rm -f $2/drawable-xhdpi/default_wallpaper.jpg
rm -f $2/drawable-hdpi/default_wallpaper.jpg
fi