Mods Folder Broom

SCREENSHOTS
Downloaded 298 times 27 Thanks 5 Favourited 2,542 Views
 Say Thanks!
This script is a Windows console application that offers a few solutions to common headaches when dealing with more than a dozen of mods. Features include forming lists based on various criteria, folder analysis, moving and soft-deleting files (by moving them to the recycle bin so they can be restored if necessary). Supports three languages (English, Russian and German) by default and loads the localization from external JSON files for easy translation process.

On startup, the script verifies the presence of Resource.cfg inside the Mods folder to verify the path and GameVersion.txt in the parent directory.

Core functions:

1. List overly nested mods
  • Lists all the files nested deeper than first nesting level (i.e., starting from Mods/Folder/SubFolder/...).
  • Detects only .ts4script files by default, as script mods simply won't work when nested too deeply.
2. List duplicates
  • Lists pairs of files with the same name, regardless of where they're located in the Mods folder.
3. List unnecessary files
  • Lists and prompts to delete ""garbage"" files that are neither mods themselves nor used by mods, such as .txt, .png, and so on.
  • Please note that while I've tried to account for all possible file extensions used by mods, I might've overlooked something, so read the list carefully before deleting them.
4. List all files
  • Lists all files from oldest to newest. Might be useful when you're trying to get rid of old and potentially broken CC/mods. DOES NOT tell you if the mods/CC listed are broken or not, only the last date the file was modified (according to the system).
  • Set to .ts4script only by default.
Extensions ignored by default:
  • .ts4script
  • .package
  • .json
  • .log
  • .ini
  • .dict
  • .dat
  • .cfg
Files ignored by default:
  • mc_lastexception.html
  • BE-Scanning.html
  • DO NOT DELETE THIS FOLDER
5. List files modified before [date]
  • Self-explanatory.
6. Find and manage file
  • Prompts a search query (supports regular expressions) and scans the entire Mods folder. After you get the list, you can:
  • Move the files to a specified folder (if the folder doesn't exist, it will create it for you). Please note than you have to enter the full path to the folder, e.g. C:\Users\User\Documents\Electronic Arts\The Sims 4\Mods\My New Folder
  • Move the files to recycle bin (so you can restore them later if you change your mind).
  • Just hit the ""enter"" button and do nothing.
7. Find similar files
  • [Experimental]
  • Prompts a search query and similarity threshold. Forms a list of files that pass the threshold, which is calculated either in percentages or by a number of matching symbols.
8. Edit settings
  • Allows you to change the settings, duh.
  • You can also do that by editing settings.json file.
  • Some changes require restarting the app.
List:
  1. Path to Mods folder: Self-explanatory.
  2. Allowed extensions: What type of files the app won't include in ""garbage files"" list.
  3. Which file extensions to list in file list: self-explanatory.
  4. Ignored directories: what folders the app will always ignore.
  5. Ignored files: same but files.
  6. Search mode for nested files: what type of files the app should include in the list. Currently only supports .ts4script and .package.
  7. Include query in similarity calculation: if your query was ""AuthorName"", should it calculate the similarity level including your query or not?
  8. Back to menu.
9. Change language
  • Almost all UI text (with the exception of a few extreme situations) is loaded from an external .json file selected by the user, which makes translation process simple and quick. For now, the app comes with English, Russian and German translations.
10. Exit
  • You won't believe what it does.

How to install
  1. Unarchive the app to The Sims 4 folder.
  2. Run the script and go to the settings menu or open settings.json file and change the path to the Mods folder to your actual one. If you've modified the settings file directly and the script crashes, make sure you use \\ as a separator and not \ or / (e.g. C:\\Users\\user\\Documents\\Electronic Arts\\The Sims 4\\Mods). The script itself should accept it with \
  3. Restart or run the script. If you've done everything correctly, it should display the game version and won't complain about the Resource.cfg missing (this file is not actually required, but it's the easiest way to verify the path is correct).
  4. This app was reviewed by the Mod The Sims moderation team and has open-source code available on GitHib. If your antivirus blocks the download, unfortunately, there're only two things I can offer: either compile the source code yourself or tell your antivirus to shut up and temporarily disable it/add necessary exclusions. Why this happens? Some modern antiviruses are overly cautionary towards new and potentially suspicious files and especially apps. Sometimes, they block all .exe files unless they have a special digital signature, which has to be issued by Microsoft and costs a few hundred dollars per year. If you're a dedicated developer/company that profits from the software you're developing, it's a must have, but it's obviously not an option for independent hobbyists developing freeware.

Future plans
  • MacOS release... sometime soon.
  • I'm NOT planning to add cache cleanup feature. I don't think it would be ethical towards Andirz to do (as he has a script that does exactly that) - and while yes, it's locked behind a paywall, it's also the easiest "script" to write imaginable that anyone can google how to make and make it in less than five minutes, so I frankly consider it a "laziness tax" and I would frankly do the same in his place.
  • If you have any suggestions or found any bugs, please let me know; in that case, I might also ask you to archive your mods folder and send it to me for experiments.
Advertisement:
Other Download Recommendations:
More downloads by Aravyn: See more