docs: Version 1.2.1, Dokumentation und Man-Page aktualisieren
- Versionsnummer auf 1.2.1 hochgesetzt - Man-Page: NO_COLOR Umgebungsvariable dokumentiert (ENVIRONMENT-Abschnitt) - Man-Page: Konfigurationsreihenfolge mit Prioritäten korrigiert - Man-Page: --no-color Beschreibung um NO_COLOR-Referenz ergänzt - README: Hilfe-Ausgabe aktualisiert (fehlende Optionen: -r, --max-depth, -s, -L, --conf, --no-color) - README: NO_COLOR Hinweis in deutsch und englisch ergänzt Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
parent
a72dae1a60
commit
92a3d66645
4 changed files with 57 additions and 32 deletions
2
Cargo.lock
generated
2
Cargo.lock
generated
|
|
@ -4,7 +4,7 @@ version = 4
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "NameToUnix"
|
name = "NameToUnix"
|
||||||
version = "1.2.0"
|
version = "1.2.1"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"anyhow",
|
"anyhow",
|
||||||
"assert_cmd",
|
"assert_cmd",
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
[package]
|
[package]
|
||||||
name = "NameToUnix"
|
name = "NameToUnix"
|
||||||
version = "1.2.0"
|
version = "1.2.1"
|
||||||
edition = "2021"
|
edition = "2021"
|
||||||
authors = ["Dieter Schlüter <dschlueter@kitux.de>"]
|
authors = ["Dieter Schlüter <dschlueter@kitux.de>"]
|
||||||
description = "Ein Tool zum Anpassen von Verzeichnis- und Dateinamen an Linux-Konventionen"
|
description = "Ein Tool zum Anpassen von Verzeichnis- und Dateinamen an Linux-Konventionen"
|
||||||
|
|
|
||||||
58
README.md
58
README.md
|
|
@ -338,21 +338,28 @@ Ein Tool zum Anpassen von Verzeichnis- und Dateinamen an Linux-Konventionen
|
||||||
Usage: ntu [OPTIONS] [PATHS]...
|
Usage: ntu [OPTIONS] [PATHS]...
|
||||||
|
|
||||||
Arguments:
|
Arguments:
|
||||||
[PATHS]... Pfade (Dateien und Verzeichnisse) zum rekursiven Anpassen
|
[PATHS]... Pfade (Dateien und Verzeichnisse) zum rekursiven Anpassen
|
||||||
|
|
||||||
Options:
|
Options:
|
||||||
-q, --quiet Ausgaben unterdrücken (keine Umbenennungsinfos auf stdout)
|
--conf <FILE> Explizite Konfigurationsdatei (bypassed Standard-Hierarchie)
|
||||||
-n, --dry-run Nur anzeigen, aber keine realen Änderungen vornehmen (dry-run)
|
-r, --recursive Rekursive Verarbeitung von Unterverzeichnissen aktivieren
|
||||||
-f, --force Existierende Dateien überschreiben
|
--max-depth <N> Maximale Rekursionstiefe (erfordert --recursive)
|
||||||
-e, --exclude <PATTERN> Zu ignorierende Muster (-e "*.py", mehrere können angegeben werden)
|
-s, --sequence <NAME> Wählt eine Transformations-Sequenz aus (default, lower, upper, minimal, utf-8)
|
||||||
-v, --verbose Ausführliche Debug-Informationen
|
-L Listet alle verfügbaren Sequences auf
|
||||||
--modify-root Erlaubt, auch das Wurzelverzeichnis anzupassen
|
-q, --quiet Ausgaben unterdrücken (keine Umbenennungsinfos auf stdout)
|
||||||
--special Auch symbolische Links und Special Files verarbeiten
|
-n, --dry-run Nur anzeigen, aber keine realen Änderungen vornehmen (dry-run)
|
||||||
-h, --help Print help
|
-f, --force Existierende Dateien überschreiben
|
||||||
-V, --version Print version
|
-e, --exclude <PATTERN> Zu ignorierende Muster (-e "*.py", mehrere können angegeben werden)
|
||||||
|
-v, --verbose Ausführliche Debug-Informationen
|
||||||
|
--modify-root Erlaubt, auch das Wurzelverzeichnis anzupassen
|
||||||
|
--special Auch symbolische Links und Special Files verarbeiten
|
||||||
|
--no-color Deaktiviert farbige Ausgabe
|
||||||
|
-h, --help Print help
|
||||||
|
-V, --version Print version
|
||||||
```
|
```
|
||||||
|
|
||||||
|
Farbige Ausgabe kann auch über die Umgebungsvariable `NO_COLOR` deaktiviert werden (siehe https://no-color.org/).
|
||||||
|
|
||||||
### Usage of NameToUnix
|
### Usage of NameToUnix
|
||||||
|
|
||||||
```text
|
```text
|
||||||
|
|
@ -361,21 +368,28 @@ A tool for adapting directories and file names to Linux conventions
|
||||||
Usage: ntu [OPTIONS] [PATHS]...
|
Usage: ntu [OPTIONS] [PATHS]...
|
||||||
|
|
||||||
Arguments:
|
Arguments:
|
||||||
[PATHS]... Paths (files and directories) for recursive customization
|
[PATHS]... Paths (files and directories) for recursive customization
|
||||||
|
|
||||||
Options:
|
Options:
|
||||||
-q, --quiet Suppress output (no renaming info on stdout)
|
--conf <FILE> Explicit config file (bypasses default hierarchy)
|
||||||
-n, --dry-run Only display, but do not make any real changes (dry-run)
|
-r, --recursive Enable recursive processing of subdirectories
|
||||||
-f, --force Overwrite existing files
|
--max-depth <N> Maximum recursion depth (requires --recursive)
|
||||||
-e, --exclude <PATTERN> Patterns to be ignored (-e "*.py", several can be specified)
|
-s, --sequence <NAME> Select a transformation sequence (default, lower, upper, minimal, utf-8)
|
||||||
-v, --verbose Detailed debug information
|
-L List all available sequences
|
||||||
--modify-root Allows you to customize the root directory as well
|
-q, --quiet Suppress output (no renaming info on stdout)
|
||||||
--special Also process symbolic links and special files
|
-n, --dry-run Only display, but do not make any real changes (dry-run)
|
||||||
-h, --help Print help
|
-f, --force Overwrite existing files
|
||||||
-V, --version Print version
|
-e, --exclude <PATTERN> Patterns to be ignored (-e "*.py", several can be specified)
|
||||||
|
-v, --verbose Detailed debug information
|
||||||
|
--modify-root Allows you to customize the root directory as well
|
||||||
|
--special Also process symbolic links and special files
|
||||||
|
--no-color Disable colored output
|
||||||
|
-h, --help Print help
|
||||||
|
-V, --version Print version
|
||||||
```
|
```
|
||||||
|
|
||||||
|
Colored output can also be disabled via the `NO_COLOR` environment variable (see https://no-color.org/).
|
||||||
|
|
||||||
## Test
|
## Test
|
||||||
|
|
||||||
Im Verzeichnis [***./test***](./test) gibt es ein bash-Skript [***create_test_tree.sh***](test/create_test_tree.sh), das lokal 21 Test-Verzeichnisse und 400 Dateien mit skurrilen Zufallsnamen erzeugt. Damit kannst Du ***NameToUnix*** ausprobieren:
|
Im Verzeichnis [***./test***](./test) gibt es ein bash-Skript [***create_test_tree.sh***](test/create_test_tree.sh), das lokal 21 Test-Verzeichnisse und 400 Dateien mit skurrilen Zufallsnamen erzeugt. Damit kannst Du ***NameToUnix*** ausprobieren:
|
||||||
|
|
|
||||||
27
man/ntu.1
27
man/ntu.1
|
|
@ -1,4 +1,4 @@
|
||||||
.TH NTU 1 "2025-02-12" "NameToUnix 1.2.0" "User Commands"
|
.TH NTU 1 "2026-02-13" "NameToUnix 1.2.1" "User Commands"
|
||||||
.SH NAME
|
.SH NAME
|
||||||
ntu \- sanitize file and directory names to Unix conventions
|
ntu \- sanitize file and directory names to Unix conventions
|
||||||
.SH SYNOPSIS
|
.SH SYNOPSIS
|
||||||
|
|
@ -55,7 +55,8 @@ Allow renaming of the root directory itself (normally skipped)
|
||||||
Process symbolic links and special files (normally skipped)
|
Process symbolic links and special files (normally skipped)
|
||||||
.TP
|
.TP
|
||||||
.BR \-\-no\-color
|
.BR \-\-no\-color
|
||||||
Disable colored output
|
Disable colored output. The \fBNO_COLOR\fR environment variable is also
|
||||||
|
respected (see \fIhttps://no-color.org/\fR).
|
||||||
.TP
|
.TP
|
||||||
.BR \-h ", " \-\-help
|
.BR \-h ", " \-\-help
|
||||||
Print help information
|
Print help information
|
||||||
|
|
@ -180,18 +181,28 @@ Symlinks are still not followed (targets remain unchanged)
|
||||||
Safe: only the link itself is renamed, not what it points to
|
Safe: only the link itself is renamed, not what it points to
|
||||||
.SH CONFIGURATION
|
.SH CONFIGURATION
|
||||||
.B ntu
|
.B ntu
|
||||||
looks for configuration files in the following locations (in order):
|
looks for configuration files in the following locations. Later files
|
||||||
|
override earlier ones (highest priority last):
|
||||||
.PP
|
.PP
|
||||||
.nf
|
.nf
|
||||||
.RS
|
.RS
|
||||||
./.NameToUnix.conf
|
1. /etc/NameToUnix/config.toml (system-wide, lowest priority)
|
||||||
~/.config/NameToUnix/config.toml
|
2. ~/.config/NameToUnix/config.toml (user-specific)
|
||||||
/etc/NameToUnix/config.toml
|
3. ./.NameToUnix.conf (working directory, highest priority)
|
||||||
.RE
|
.RE
|
||||||
.fi
|
.fi
|
||||||
.PP
|
.PP
|
||||||
Configuration files can customize character replacements and other behavior.
|
When using \fB\-\-conf\fR, the standard hierarchy is bypassed and only the
|
||||||
See the project documentation for configuration file format.
|
specified file is loaded.
|
||||||
|
.PP
|
||||||
|
Configuration files use TOML format with a \fB[replacements]\fR section
|
||||||
|
for custom character replacements. See the project documentation for details.
|
||||||
|
.SH ENVIRONMENT
|
||||||
|
.TP
|
||||||
|
.B NO_COLOR
|
||||||
|
When set (to any value), colored output is disabled. This follows the
|
||||||
|
convention described at \fIhttps://no-color.org/\fR. The \fB\-\-no\-color\fR
|
||||||
|
flag has the same effect.
|
||||||
.SH EXIT STATUS
|
.SH EXIT STATUS
|
||||||
.TP
|
.TP
|
||||||
.B 0
|
.B 0
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue