Commit c593fa7
authored
feat: add advanced dpkg/apt lock fixer script for Termux (#6)
* Add French translation and fix STATE_FILE in explain.sh
* feat: add advanced dpkg/apt lock fixer script for Termux
Description
On some Termux environments (especially non-rooted recent Android versions like Android 13/14 on Xiaomi/Redmi devices), the standard tdoc fix routine might fail to completely release or detect stale dpkg or apt frontend locks.
This script provides a safe, automated, and strict fallback method:
It checks if an actual apt or dpkg process is running to prevent breaking active installations.
If no active PID is found, it forcefully removes the standard orphan lock files (lock, lock-frontend, etc.).
It triggers a final verification via tdoc doctor.
Environment tested:
Termux 0.118.3
Device: Xiaomi Redmi Note 13 Pro+ 5G (Android 13 / SDK 33, non-rooted)
Feel free to integrate this logic into the main core or keep it as a standalone helper script (tdocfix.sh).
* Fix dependabot labels1 parent 6449729 commit c593fa7
2 files changed
Lines changed: 43 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
10 | | - | |
11 | | - | |
12 | | - | |
13 | 10 | | |
14 | 11 | | |
15 | 12 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 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 | + | |
0 commit comments