Skip to content
This repository has been archived by the owner on Jan 8, 2024. It is now read-only.

Commit

Permalink
Remove unneeded rename
Browse files Browse the repository at this point in the history
  • Loading branch information
RikkaW committed Mar 26, 2021
1 parent 0a385b9 commit 60d951e
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 14 deletions.
8 changes: 3 additions & 5 deletions template/magisk_module/customize.sh
Original file line number Diff line number Diff line change
Expand Up @@ -103,14 +103,12 @@ ui_print "- Setting permissions"
set_perm_recursive "$MODPATH" 0 0 0755 0644

ui_print "- Moving rirud"
rm "$MODPATH/rirud.new"
mv "$MODPATH/librirud.so" "$MODPATH/rirud.new"
set_perm "$MODPATH/rirud.new" 0 0 0700
mv "$MODPATH/librirud.so" "$MODPATH/rirud"
set_perm "$MODPATH/rirud" 0 0 0700

ui_print "- Extracting rirud.dex"
extract "$ZIPFILE" "classes.dex" "$MODPATH"
rm "$MODPATH/rirud.dex.new"
mv "$MODPATH/classes.dex" "$MODPATH/rirud.dex.new"
mv "$MODPATH/classes.dex" "$MODPATH/rirud.dex"
set_perm "$MODPATH/rirud.dex.new" 0 0 0600

ui_print "- Removing old files"
Expand Down
11 changes: 2 additions & 9 deletions template/magisk_module/post-fs-data.sh
Original file line number Diff line number Diff line change
@@ -1,15 +1,8 @@
#!/system/bin/sh
MODDIR=${0%/*}

# Rename .new file
move_new_file() {
if [ -f "$1.new" ]; then
rm "$1"
mv "$1.new" "$1"
fi
}
move_new_file "$MODDIR/rirud"
move_new_file "$MODDIR/rirud.dex"
# Chmod again just in case
chmod 700 "$MODDIR"/rirud

# Start daemon which runs socket "rirud"
exec "$MODDIR"/rirud

0 comments on commit 60d951e

Please sign in to comment.