mirror of
https://github.com/revanced/revanced-manager
synced 2024-05-14 13:56:57 +02:00
fix: Do not delete files from post-fs-data.d
This commit is contained in:
parent
c7d975e612
commit
70a1086edf
@ -2,9 +2,6 @@ import 'package:flutter/foundation.dart';
|
||||
import 'package:root/root.dart';
|
||||
|
||||
class RootAPI {
|
||||
// TODO(aAbed): remove in the future, keep it for now during migration.
|
||||
final String _postFsDataDirPath = '/data/adb/post-fs-data.d';
|
||||
|
||||
final String _revancedDirPath = '/data/adb/revanced';
|
||||
final String _serviceDDirPath = '/data/adb/service.d';
|
||||
|
||||
@ -99,18 +96,9 @@ class RootAPI {
|
||||
);
|
||||
}
|
||||
|
||||
// TODO(aAbed): remove in the future, keep it for now during migration.
|
||||
Future<void> removeOrphanedFiles() async {
|
||||
await Root.exec(
|
||||
cmd: '''
|
||||
find $_revancedDirPath -type f -name original.apk -delete
|
||||
for file in "$_serviceDDirPath"/*; do
|
||||
filename=\$(basename "\$file")
|
||||
if [ -f "$_postFsDataDirPath/\$filename" ]; then
|
||||
rm "$_postFsDataDirPath/\$filename"
|
||||
fi
|
||||
done
|
||||
''',
|
||||
cmd: 'find $_revancedDirPath -type f -name original.apk -delete',
|
||||
);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user