Update README.md

This commit is contained in:
RatzzFatzz
2025-02-04 13:56:29 +01:00
parent 44d2601d3e
commit 0813744148

View File

@@ -1,49 +1,61 @@
## Introduction ## Introduction
This program helps to change audio and subtitle tracks of mkv files without rewriting the file. Only track properties will be updated. A streamlined solution for managing MKV files, this program leverages MKVToolNix to modify audio and subtitle track properties without the need for time-consuming file reencoding. Users can easily set their track preferences, and the application intelligently applies the best matching configuration. The tool focuses on metadata modification rather than full file rewriting, ensuring quick operations while maintaining the original file integrity. This makes it an ideal choice for managing multilingual media collections or batch processing multiple MKV files.
![](https://github.com/RatzzFatzz/MKVAudioSubtitleChanger/blob/master/example.gif) ![](https://github.com/RatzzFatzz/MKVAudioSubtitleChanger/blob/master/example.gif)
## Requirements ## Requirements
- Java 11 or higher - Java 21 or newer
- mkvtoolnix installation - mkvtoolnix installation
## Execution ## Execution
**Minimal usage:** ### Minimal usage
`java -jar mkvaudiosubtitlechanger.jar --library "X:/Files" --attribute-config eng:ger eng:OFF` Portable: `java -jar mkvaudiosubtitlechanger-<version>.jar --library "X:/Files" --attribute-config eng:ger eng:OFF`
**Safe usage (best for testing before applying to whole library):** Windows (installed): `mkvaudiosubtitlechanger.jar --library "X:/Files" --attribute-config eng:ger eng:OFF`
`java -jar mkvaudiosubtitlechanger.jar --library "X:/Files" --attribute-config eng:ger eng:OFF --safe-mode`
Attribute-config must be entered in pairs: `audio:subtitle`; Example: `jpn:eng`. More about this topic ### Safe usage (best for testing before applying to whole library)
[here](https://github.com/RatzzFatzz/MKVAudioSubtitleChanger/wiki/Attribute-Config). Portable: `java -jar mkvaudiosubtitlechanger-<version>.jar --library "X:/Files" --attribute-config eng:ger eng:OFF --safe-mode`
Windows (installed): `mkvaudiosubtitlechanger.jar --library "X:/Files" --attribute-config eng:ger eng:OFF --safe-mode`
**Attribute-config must be entered in pairs: `audio:subtitle`; Example: `jpn:eng`. More about this topic
[here](https://github.com/RatzzFatzz/MKVAudioSubtitleChanger/wiki/Attribute-Config).**
## Available parameters ## Available parameters
``` ```
-l,--library-path <arg> Path to library -a, --attribute-config=<attributeConfig>...
-a,--attribute-config <arg> Attribute config to decide which tracks to choose when List of audio:subtitle pairs used to match in order and update files accordingly (e.g. jpn:eng jpn:ger)
-p,--config-path <arg> Path to config file -c, --coherent=<coherent> try to match all files in dir of depth with the same attribute config
-m,--mkvtoolnix <arg> Path to mkv tool nix installation -cf, --force-coherent changes are only applied if it's a coherent match
-s,--safe-mode Test run (no files will be changes) --commentary-keywords=<commentaryKeywords>[, <commentaryKeywords>...]...
-c,--coherent <arg> Try to match all files in dir of depth with the same config Keywords to identify commentary tracks (Defaults will be overwritten; Default: commentary, director)
-cf,--force-coherent Force coherent and don't update anything if config fits not whole config (default: false) -d, --filter-date=<filterDate>
-n,--only-new-files Sets filter-date to last successful execution (Overwrites input of filter-date) only consider files created newer than entered date (format: "dd.MM.yyyy-HH:mm:ss")
-d,--filter-date <arg> Only consider files created newer than entered date (format: "dd.MM.yyyy-HH:mm:ss") -e, --excluded-directory=<excludedDirectories>...
-t,--threads <arg> Thread count (default: 2) Directories to be excluded, combines with config file
-i,--include-pattern <arg> Include files matching pattern (default: ".*") --forced-keywords=<forcedKeywords>[, <forcedKeywords>...]...
-e,--excluded-directories <arg> Directories to be excluded, combines with config file Keywords to identify forced tracks (Defaults will be overwritten; Default: forced, signs, songs)
-fk,--forced-keywords <arg> Additional keywords to identify forced tracks -h, --help Show this help message and exit.
-ck,--commentary-keywords <arg> Additional keywords to identify commentary tracks -i, --include-pattern=<includePattern>
-ps,--preferred-subtitles <arg> Additional keywords to prefer specific subtitle tracks include files matching pattern (default: ".*")
-v,--version Display version -l, --library=<libraryPath>
-h,--help "For help this is" - Yoda path to library
-m, --mkvtoolnix=<mkvToolNix>
path to mkvtoolnix installation
-n, --only-new-file sets filter-date to last successful execution (overwrites input of filter-date)
--preferred-subtitles=<preferredSubtitles>[, <preferredSubtitles>...]...
Keywords to prefer specific subtitle tracks (Defaults will be overwritten; Default: unstyled)
-s, --safemode test run (no files will be changes)
-t, --threads=<threads> thread count (default: 2)
-V, --version Print version information and exit.
``` ```
If you need more information about how each parameter works, check out [this wiki page](https://github.com/RatzzFatzz/MKVAudioSubtitleChanger/wiki/Parameters). If you need more information how each parameter works, check out [this wiki page](https://github.com/RatzzFatzz/MKVAudioSubtitleChanger/wiki/Parameters).
All parameters can also be defined in a [config file](https://github.com/RatzzFatzz/MKVAudioSubtitleChanger/wiki/How-to-config-file). All parameters can also be defined in a [config file](https://github.com/RatzzFatzz/MKVAudioSubtitleChanger/wiki/How-to-config-file).
## Build requirements ## Build requirements
- JDK 11 or higher - JDK 21 or newer
- Maven 3 - Maven 3
- Git - Git
@@ -51,5 +63,5 @@ All parameters can also be defined in a [config file](https://github.com/RatzzFa
```shell ```shell
git clone https://github.com/RatzzFatzz/MKVAudioSubtitleChanger.git git clone https://github.com/RatzzFatzz/MKVAudioSubtitleChanger.git
cd MKVAudioSubtitleChanger cd MKVAudioSubtitleChanger
mvn package mvn clean package -Pportable
``` ```