Update README.md

This commit is contained in:
David Maisonave
2024-08-06 02:25:58 -04:00
committed by GitHub
parent 1f2ac6bed7
commit a830029cc1

View File

@@ -1,41 +1,32 @@
# This Plugin is under construction!!! # StashPluginHelper: Ver 0.1.0 (By David Maisonave)
StashPluginHelper is a class that performs common implementation used in most plugins.
# DupFileManager: Ver 0.1.0 (By David Maisonave)
DupFileManager is a [Stash](https://github.com/stashapp/stash) plugin which manages duplicate file in the Stash system.
### Features ### Features
- Can merge potential source in the duplicate file names for tag names, performers, and studios. - Log Features:
- Normally when Stash searches the file name for tag names, performers, and studios, it only does so using the primary file. This plugin scans the duplicate files to see if additional fields are available. - Optionally log out to multiple outputs for each Log or Trace call.
- Delete duplicate file task with the following options: - Logging includes source code line number.
- Options in plugin UI (Settings->Plugins->Plugins->[DupFileManager]) - Sets a maximum plugin log file size.
- Ignore reparse-points. By default, reparse-points are not deleted. - Stash Interface Features:
- Ignore symbolic links. By default, symbolic links are not deleted. - Sets STASH_INTERFACE with StashInterface
- Before deletion, merge potential source in the duplicate file names for tag names, performers, and studios. - Gets STASH_URL value from command line argument and/or from STDIN_READ
- Optionally permanently duplicates or moved them to **trash can** / alternate folder. - Sets FRAGMENT_SERVER based on command line arguments or STDIN_READ
- Options available via DupFileManager_config.py - Sets PLUGIN_ID based on the main script file name (in lower case)
- Use a white list of preferential directories to determine which duplicate should be the primary. - Gets PLUGIN_TASK_NAME value
- Use a black list to determine which duplicates should be deleted first. - Sets pluginSettings (The plugin UI settings)
- Use an ignore list to avoid specific directories. No action is taken on any file in the ignore list. - Misc Features:
- Target directories list. If this list is populated, only files under these directories are process. If list is empty, all files are processed (excluding those in ignore list). - Gets DRY_RUN value from command line argument and/or from UI and/or from config file.
- Alternative path to move duplicate files. Path needs to be in the same drive as the duplicate file. - Gets DEBUG_TRACING value from command line argument and/or from UI and/or from config file.
- Example: "C:\TempDeleteFolder" - Sets RUNNING_IN_COMMAND_LINE_MODE to True if detects multiple arguments
- Sets CALLED_AS_STASH_PLUGIN to True if it's able to read from STDIN_READ
### Using DupFileManager ### Using StashPluginHelper
This Plugin is under construction!!! from filemonitor_config import config
settings = {
"recursiveDisabled": False,
"zzdebugTracing": False,
"zzdryRun": False,
}
plugin = StashPluginHelper(settings=settings, config=config)
### Requirements ### Requirements
`pip install stashapp-tools` `pip install stashapp-tools --upgrade`
`pip install --upgrade stashapp-tools`
`pip install pyYAML`
### Installation
- Follow **Requirements** instructions.
- In the stash plugin directory (C:\Users\MyUserName\.stash\plugins), create a folder named **DupFileManager**.
- Copy all the plugin files to this folder.(**C:\Users\MyUserName\\.stash\plugins\DupFileManager**).
- Click the **[Reload Plugins]** button in Stash->Settings->Plugins->Plugins.
That's it!!!
### Options
- Options are accessible in the GUI via Settings->Plugins->Plugins->[DupFileManager].
- More options available in DupFileManager_config.py.