Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

v2.9.2 #76

Merged
merged 16 commits into from
Mar 21, 2019
Merged
Show file tree
Hide file tree
Changes from 10 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
# Auto detect text files and perform LF normalization
* text=auto
#track Large Files
*.xz filter=lfs diff=lfs merge=lfs -text
# Declare files that will always have LF line endings on checkout.
*.sh text eol=lf
*.prop text eol=lf
Expand Down
14 changes: 11 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ As a Mi A1 user, I was stuck with Stock Oreo 8.0.0 without Oreo custom ROMs when
- OVER = Install pixel overlays
- ACC = Install pixel accent
- BOOT = Install pixel boot animation
- FONT = Install pixel fonts
- To use the basename zip feature all you need to do is add the options to the zipname and only flash the zip in recovery. Magisk renames all zips to install.zip so flashing in magisk manager will NOT work. Heres an example of using basename to install full and overlays ( Pix3lify-2.6-full-over.zip )
- The options can either be full, Full, or FULL ( applies to all options )

Expand All @@ -54,11 +55,18 @@ As a Mi A1 user, I was stuck with Stock Oreo 8.0.0 without Oreo custom ROMs when
- Enables Google Assistant
- Enables Night Light (device dependent)

## ⭐ Features Under Development
## ⭐ Changelog
thehappydinoa marked this conversation as resolved.
Show resolved Hide resolved

- Flip to Shhh (mileage may vary)
### v2.9.1
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Bump

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Version change, right?


## ⭐ Changelog
- Fix hanging in terminal script
- Detect if dialer is installed
- Fix find command
- Remove autoDND/flip to shhh
- Fix Wellbeing
- Bug fixes
- Unity update
- Add font option

### v2.9

Expand Down
Binary file modified addon.tar.xz
Binary file not shown.
5 changes: 0 additions & 5 deletions common/PhenotypePrefs.xml

This file was deleted.

78 changes: 47 additions & 31 deletions common/install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -61,14 +61,15 @@ patch_xml() {
}

# Gets stock/limit from zip name
SLIM=false; FULL=false; OVER=false BOOT=false; ACC=false
SLIM=false; FULL=false; OVER=false BOOT=false; ACC=false; FONT=false
OIFS=$IFS; IFS=\|
case $(echo $(basename $ZIPFILE) | tr '[:upper:]' '[:lower:]') in
*slim*|*Slim*|*SLIM*) SLIM=true;;
*full*|*Full*|*FULL*) FULL=true;;
*over*|*Over*|*OVER*) OVER=true;;
*boot*|*Boot*|*BOOT*) BOOT=true;;
*acc*|*Acc*|*ACC*) ACC=true;;
*font*|*Font*|*FONT*) FONT=true;;
esac
IFS=$OIFS

Expand Down Expand Up @@ -132,27 +133,34 @@ if [ "$SLIM" == false -a "$FULL" == false -a "$OVER" == false -a "$BOOT" == fals
fi
fi
ui_print " "
log_print " - Overlay Options -"
log_print " Do you want the Res overlays enabled?"
log_print " - Font Options -"
log_print " Do you want to install custom fonts?"
log_print " Vol Up = Yes, Vol Down = No"
if $VKSEL; then
OVER=true >> $INSTLOG 2>&1
FONT=true >> $INSTLOG 2>&1
ui_print " "
log_print " - Accent Options -"
log_print " Do you want the Pixel accent enabled?"
log_print " - Overlay Options -"
log_print " Do you want the Res overlays enabled?"
log_print " Vol Up = Yes, Vol Down = No"
if $VKSEL; then
ACC=true >> $INSTLOG 2>&1
OVER=true >> $INSTLOG 2>&1
ui_print " "
log_print " - Accent Options -"
log_print " Do you want the Pixel accent enabled?"
log_print " Vol Up = Yes, Vol Down = No"
if $VKSEL; then
ACC=true >> $INSTLOG 2>&1
fi
fi
fi
fi
ui_print " "
log_print " - Animation Options -"
log_print " Do you want the Pixel boot animation?"
log_print " Vol Up = Yes, Vol Down = No"
if $VKSEL; then
BOOT=true >> $INSTLOG 2>&1
fi
ui_print " "
log_print " - Animation Options -"
log_print " Do you want the Pixel boot animation?"
log_print " Vol Up = Yes, Vol Down = No"
if $VKSEL; then
BOOT=true >> $INSTLOG 2>&1
fi
else
log_print " Options specified in zip name!"
fi
Expand Down Expand Up @@ -213,20 +221,37 @@ if $BOOT; then
ui_print " "
log_print " Enabling boot animation..."
cp_ch -i $INSTALLER/common/bootanimation.zip $UNITY$BFOLDER$BZIP

else
ui_print " "
log_print " Disabling boot animation..."
fi

if $FONT; then
ui_print " "
log_print " Enabling fonts..."
cp -rf /system/etc/fonts.xml $INSTALLER/system/etc/fonts.xml
for i in $(find $INSTALLER/system/fonts/GoogleSans-* | sed 's|.*-||'); do
sed -i "s|Roboto-$i|GoogleSans-$i|" $INSTALLER/system/etc/fonts.xml
done
for i in $(find /system/fonts/Clock* | sed 's|.*-||'); do
sed -i "s|Clock$i|GoogleSans-Regular|" $INSTALLER/system/etc/fonts.xml
ui_print " "
log_print " Replacing LockScreen Font.."
done
else
ui_print " "
log_print " Disabling fonts..."
rm -rf $INSTALLER/system/fonts >> $INSTLOG 2>&1
fi

if [ $API -ge 27 ]; then
rm -rf $INSTALLER/system/framework >> $INSTLOG 2>&1
fi

if [ $API -ge 28 ]; then
ui_print " "
log_print " Enabling Google's Call Screening..."
DPF=$(find /data/data/com.google.android.dialer*/shared_prefs/ -name "dialer_phenotype_flags.xml")
DPF=$(find /data/data/com.google.android.dialer* -name "dialer_phenotype_flags.xml")
if [ -f $DPF ]; then
# Enabling Google's Call Screening
patch_xml -s $DPF '/map/boolean[@name="G__speak_easy_bypass_locale_check"]' "true" >> $INSTLOG 2>&1
Expand All @@ -241,27 +266,18 @@ if [ $API -ge 28 ]; then
fi
fi

if [ "$SLIM" == "false" ]; then
ui_print " "
log_print " Enabling Google's Flip to Shhh..."
ui_print " "
# Enabling Google's Flip to Shhh
WELLBEING_PREF_FILE=$INSTALLER/common/PhenotypePrefs.xml
chmod 660 $WELLBEING_PREF_FILE
WELLBEING_PREF_FOLDER=$(find /data/data/com.google.android.apps.wellbeing* -name "shared_prefs")
mkdir -p $WELLBEING_PREF_FOLDER
cp_ch $WELLBEING_PREF_FILE $WELLBEING_PREF_FOLDER
if $MAGISK && $BOOTMODE; then
magiskpolicy --live "create system_server sdcardfs file" "allow system_server sdcardfs file { write }"
am force-stop "com.google.android.apps.wellbeing"
fi
if [ $API -lt 28 ]; then
rm -rf $MODPATH/system/app/MarkupGoogle1.apk
mv $MODPATH/system/app/MarkupGoogle2.apk $MODPATH/system/app/MarkupGoogle.apk
else
rm -rf $MODPATH/system/app/MarkupGoogle2.apk
mv $MODPATH/system/app/MarkupGoogle1.apk $MODPATH/system/app/MarkupGoogle.apk
fi

# Adds slim & full variables to service.sh
for i in "SLIM" "FULL"; do
sed -i "2i $i=$(eval echo \$$i)" $INSTALLER/common/service.sh
done
cp_ch -n $INSTALLER/common/service.sh $UNITY/service.sh

cp_ch -i $INSTALLER/common/unityfiles/tools/$ARCH32/xmlstarlet $INSTALLER/system/bin/xmlstarlet

Expand Down
4 changes: 2 additions & 2 deletions common/post-fs-data.sh
Original file line number Diff line number Diff line change
Expand Up @@ -67,10 +67,10 @@ patch_xml() {

(
if [ $API -ge "28" ]; then
DPF=$(find /data/data/com.google.android.dialer*/shared_prefs/ -name "dialer_phenotype_flags.xml")
DPF=$(find /data/data/com.google.android.dialer* -name "dialer_phenotype_flags.xml")
if [ -f $DPF ]; then
# Enabling Google's Call Screening
#DIALERPATCHES
fi
fi
)&
)&
2 changes: 1 addition & 1 deletion common/sepolicy.sh
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
# Put sepolicy statements here
# Example: allow { audioserver mediaserver } audioserver_tmpfs file { read write open }
create system_server sdcardfs file allow system_server sdcardfs file { write }
"create system_server sdcardfs file" "allow system_server sdcardfs file { write }"
1 change: 0 additions & 1 deletion common/service.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
# More info in the main Magisk thread

if [ $API -ge 28 ] && [ $FULL ]; then
pm enable "com.google.android.apps.wellbeing/com.google.android.apps.wellbeing.autodnd.ui.AutoDndGesturesSettingsActivity"
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Figure out how to remove updates before installing WellBeing

Copy link
Collaborator

@lzlrd lzlrd Mar 17, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are you referring to Aurora's method? Pretty sure @Stallix tested and it doesn't work.

I guess this line is unnecessary code then too.

If we did want to remove updates it would be a part of the pm --uninstall command or wiping /data/data/x and /data/app/x.

am force-stop "com.google.android.apps.wellbeing"
if [[ $(pm list packages "com.google.android.soundpicker") ]]; then
pm grant com.google.android.soundpicker android.permission.READ_EXTERNAL_STORAGE
Expand Down
4 changes: 2 additions & 2 deletions common/uninstall.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ fi
if [ $API -ge 28 ]; then
ui_print " "
ui_print " Disabling Google's Call Screening..."
DPF=$(find /data/data/com.google.android.dialer*/shared_prefs/ -name "dialer_phenotype_flags.xml")
DPF=$(find /data/data/com.google.android.dialer* -name "dialer_phenotype_flags.xml")
if [ -f $DPF ]; then
sed -i "/<!--$MODID-->/d" $DPF
sed -i -e "s|<!--$MODID\(.*\)|\1|g" -e "s|\(.*\)$MODID-->|\1|g" $DPF
Expand All @@ -18,7 +18,7 @@ fi
ui_print " "
ui_print " Disabling Google's Flip to Shhh..."
# Disabling Google's Flip to Shhh
WELLBEING_PREF_FILE=$(find /data/data/com.google.android.apps.wellbeing*/shared_prefs -name "PhenotypePrefs.xml")
WELLBEING_PREF_FILE=$(find /data/data/com.google.android.apps.wellbeing* -name "PhenotypePrefs.xml")
lzlrd marked this conversation as resolved.
Show resolved Hide resolved
if [ -f $WELLBEING_PREF_FILE ]; then
rm -f $WELLBEING_PREF_FILE
if $BOOTMODE; then
Expand Down
Binary file modified common/unityfiles/tools.tar.gz
Binary file not shown.
2 changes: 1 addition & 1 deletion common/unityfiles/util_functions.sh
Original file line number Diff line number Diff line change
Expand Up @@ -632,7 +632,7 @@ mount_partitions
api_level_arch_detect

# Check for min & max api version
[ -z $MINAPI ] && MINAPI=21 || { [ $MINAPI -lt 21 ] && MINAPI=21; }
[ -z $MINAPI ] && MINAPI=17 || { [ $MINAPI -lt 17 ] && MINAPI=17; }
[ $API -lt $MINAPI ] && { ui_print "! Your system API of $API is less than"; ui_print "! the minimum api of $MINAPI!"; abort "! Aborting!"; }
[ -z $MAXAPI ] || { [ $API -gt $MAXAPI ] && { ui_print "! Your system API of $API is greater than"; ui_print "! the maximum api of $MINAPI!"; abort "! Aborting!"; }; }

Expand Down
Loading