Du kannst nicht mehr als 25 Themen auswählen Themen müssen entweder mit einem Buchstaben oder einer Ziffer beginnen. Sie können Bindestriche („-“) enthalten und bis zu 35 Zeichen lang sein.

99 Zeilen
2.8 KiB
Markdown

vor 3 Wochen
# ddrescue-tui
[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
vor 3 Wochen
## Report
The report can be found in `/report/`.
The directory contains both the PDF file as well as the LaTex sources.
## Installation
### Requirements:
The following packages required:
- python3.10 or higher
- pip modules:
- matplotlib
- numpy
- textual
- rich-pixels == 2.2.0
- gddrescue
#### Optionally for development:
- pip:
- build
- setuptools
- textual-dev
### Installing
Installing so it can be used from everywhere with `ddrescue-tui` can be done with `./utilctl install` or manually with `pipx install .` inside of the project directory.
`utilctl` also installs all necessary requirements
I recommend using pipx to avoid possible conflicts
Alternatively, a .whl file can be downloaded from the releases tab and installed with pip.
**For running ddrescue directly, the package has to be run as sudo and therefore also installed with sudo.**
### Building a binary package
Building a package for binary distribution can be done with: `./utilctl build` or manually with `pipx run build`.
### Troubleshooting
If the command results in a blank terminal, the Python IO encoding might be not set to UTF-8. You can fix this with
`export PYTHONIOENCODING=utf-8` once per terminal session or by prepending the command like this: `PYTHONIOENCODING=utf-8 ddrescue-tui <ARGS>`
## Usage
```
$ ddrescue-tui -h
usage: ddrescue-tui [-h] [-i I] {open,run} ...
TUI for ddrescue, visualizes the progress using the mapfile
positional arguments:
{open,run}
open open mapfile
run run ddrescue on startup (sudo required)
options:
-h, --help show this help message and exit
-i I, --interval I Initial reload interval (default=32s)
$ ddrescue-tui open -h
usage: ddrescue-tui open [-h] [-n] mapfile
positional arguments:
mapfile mapfile to read from
options:
-h, --help show this help message and exit
-n, --noninteractive Run simple non-interactive mode
$ ddrescue-tui run -h
usage: ddrescue-tui run [-h] [-o [OUT]] [-a ARGS] INPUT OUTPUT
positional arguments:
INPUT input file or device
OUTPUT output file or folder
options:
-h, --help show this help message and exit
-o [OUT], --output_name [OUT]
output filename
-a ARGS, --arguments ARGS
Custom arguments
```
## Examples
Example mapfiles can be found in `./mapfiles`.
### Non-interactive
```bash
$ ddrescue-tui open -n mapfiles/2024-02-10_virt.map
```
![grafik](/report/img/tui_non-interactive.png)
vor 3 Wochen
```bash
# ddrescue-tui open mapfiles/2024-01-18_HDD.map
```
![grafik](/report/img/tui_interactive_1.png)
vor 3 Wochen
![grafik](/report/img/tui_interactive_2.png)
vor 3 Wochen