- creates folders specified in .env file
- sorts them according to extensions assigned to folder in .env file
- you can determine the time of refreshing script (checking for new files in your downloads folder)
pip install -r requirements.txt- NOTE: You have to be in script folder
echo '<?xml version="1.0" encoding="UTF-8"?>\n<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">\n<plist version="1.0">\n<dict>\n <key>Label</key>\n <string>com.user.yourscript</string>\n <key>ProgramArguments</key>\n <array>\n <string>/usr/bin/python3</string>\n <string>/path/to/your/script.py</string>\n </array>\n <key>RunAtLoad</key>\n <true/>\n</dict>\n</plist>' > ~/Library/LaunchAgents/com.user.downloads_filter.plist -
You have to repalce the
/path/to/your/script.pyand/usr/bin/python3(if you're not using default python version) -
Then accept any permissions popup's
-
DOWNLOADS_PATH - path to the folder you want to sort
-
REFRESH_TIME_SPAN - time [in minutes] for another refresh to occur
-
FOLDER_NAMES - folder names that you want to create/operate for sorting (they must be separated with
,-> ! without spaces) -
FILTER_EXTENSTIONS - filters must be separated by
/and contain no spaces and folders filters separator is|- NOTE: .env file has to contain same amount of folder names and filters extensions separated by
|to work properly - Folder containing rest not sorted extensions should be placed on the end of the
FOLDER_NAMESlist - Extension for rest folder should be set as
ALL_OTHER - Proper example of
.envfile you can see in repository
- NOTE: .env file has to contain same amount of folder names and filters extensions separated by
pip install -r requirements.txt- NOTE: You have to be in script folder
@echo off
C:\path\to\your\script.py
pause- replace
path\to\your\script.pywith actual path to this script on your system
- for the current user's Startup folder, the path is usually C:\Users\YourUsername\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Startup.
- replace YourUsername with your actual Windows username
copy C:\path\to\run_script.bat "C:\Users\[YourUsername]\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Startup"C:\path\to\run_script.batchange this to actual script path[YourUsername]change this to your username
