Name | download-sorter JSON |
Version |
0.1.1
JSON |
| download |
home_page | |
Summary | Organizes the files in your Downloads folder based on their file extensions. The module moves files into predefined folders according to a configuration file, making it easier to find and manage your downloaded files. |
upload_time | 2023-04-19 23:03:23 |
maintainer | |
docs_url | None |
author | DJ Stomp |
requires_python | >=3.8,<4.0 |
license | MIT |
keywords |
|
VCS |
|
bugtrack_url |
|
requirements |
No requirements were recorded.
|
Travis-CI |
No Travis.
|
coveralls test coverage |
No coveralls.
|
# DownloadSorter
DownloadSorter is a Python module that organizes the files in your Downloads folder based on their file extensions. The module moves files into predefined folders according to a configuration file, making it easier to find and manage your downloaded files.
## Features
- Organizes files directly in the Downloads folder (non-recursive)
- Customizable folder organization using a JSON configuration file
- Automatically appends Unix timestamps to filenames to avoid conflicts
- Cross-platform compatibility
## Getting Started
### Prerequisites
- Python 3.x
- JSON configuration file (default: `sort.json`)
### Installation
1. Clone the repository or download the `sort_downloads.py` file.
2. Create a JSON configuration file, if not using the provided `sort.json`.
### Configuration
The `sort.json` file defines the folder organization for different file extensions. The structure of the JSON file is as follows:
```json
{
"DestinationFolder1": ["ext1", "ext2"],
"DestinationFolder2": ["ext3", "ext4"]
}
```
For example, to organize music into the "Music" folder and image files into the "Pictures" folder, the `sort.json` file should look like this:
```json
{
"Music": [
".mp3",
".wma",
".ogg",
".wav"
],
"Pictures": [
".jpg",
".jpeg",
".png",
".gif",
".webm",
".bmp"
]
}
```
### Usage
To use the DownloadSorter, simply run the `sort_downloads.py` script:
```sh
python sort_downloads.py
```
By default, the script will organize files in the `~/Downloads` directory if you're using Windows, or `~/downloads` for non-Windows users. You can modify the `downloads_path` variable in the script to point to a different directory if needed, or pass the directory path as a command line argument when running `sort_downloads.py`.
## Customization
If you want to customize DownloadSorter, you can modify the `sort_downloads.py` script:
- Change the `config_file` parameter in the `DownloadSorter` constructor to use a different JSON configuration file.
- Update the `downloads_path` variable in the `__main__` block to use a different directory for sorting files, or pass the directory path as a command line argument when running `sort_downloads.py`.
## Contributing
Contributions are welcome! If you have any ideas, feature requests, or bug reports, feel free to submit an issue or create a pull request.
## License
This project is licensed under the MIT License. See the `LICENSE` file for details.
Raw data
{
"_id": null,
"home_page": "",
"name": "download-sorter",
"maintainer": "",
"docs_url": null,
"requires_python": ">=3.8,<4.0",
"maintainer_email": "",
"keywords": "",
"author": "DJ Stomp",
"author_email": "85457381+DJStompZone@users.noreply.github.com",
"download_url": "https://files.pythonhosted.org/packages/1a/7e/9fa351813c6a19df12c2eeb4783a038a2ed73c177964885a8de4790e94b9/download_sorter-0.1.1.tar.gz",
"platform": null,
"description": "# DownloadSorter\n\nDownloadSorter is a Python module that organizes the files in your Downloads folder based on their file extensions. The module moves files into predefined folders according to a configuration file, making it easier to find and manage your downloaded files.\n\n## Features\n\n- Organizes files directly in the Downloads folder (non-recursive)\n- Customizable folder organization using a JSON configuration file\n- Automatically appends Unix timestamps to filenames to avoid conflicts\n- Cross-platform compatibility\n\n## Getting Started\n\n### Prerequisites\n\n- Python 3.x\n- JSON configuration file (default: `sort.json`)\n\n### Installation\n\n1. Clone the repository or download the `sort_downloads.py` file.\n2. Create a JSON configuration file, if not using the provided `sort.json`.\n\n### Configuration\n\nThe `sort.json` file defines the folder organization for different file extensions. The structure of the JSON file is as follows:\n\n```json\n{\n \"DestinationFolder1\": [\"ext1\", \"ext2\"],\n \"DestinationFolder2\": [\"ext3\", \"ext4\"]\n}\n```\n\nFor example, to organize music into the \"Music\" folder and image files into the \"Pictures\" folder, the `sort.json` file should look like this:\n\n```json\n{\n \"Music\": [\n \".mp3\",\n \".wma\",\n \".ogg\",\n \".wav\"\n ],\n \"Pictures\": [\n \".jpg\",\n \".jpeg\",\n \".png\",\n \".gif\",\n \".webm\",\n \".bmp\"\n ]\n}\n```\n\n### Usage\n\nTo use the DownloadSorter, simply run the `sort_downloads.py` script:\n\n```sh\npython sort_downloads.py\n```\n\nBy default, the script will organize files in the `~/Downloads` directory if you're using Windows, or `~/downloads` for non-Windows users. You can modify the `downloads_path` variable in the script to point to a different directory if needed, or pass the directory path as a command line argument when running `sort_downloads.py`.\n\n## Customization\n\nIf you want to customize DownloadSorter, you can modify the `sort_downloads.py` script:\n\n- Change the `config_file` parameter in the `DownloadSorter` constructor to use a different JSON configuration file.\n- Update the `downloads_path` variable in the `__main__` block to use a different directory for sorting files, or pass the directory path as a command line argument when running `sort_downloads.py`.\n\n## Contributing\n\nContributions are welcome! If you have any ideas, feature requests, or bug reports, feel free to submit an issue or create a pull request.\n\n## License\n\nThis project is licensed under the MIT License. See the `LICENSE` file for details.\n",
"bugtrack_url": null,
"license": "MIT",
"summary": "Organizes the files in your Downloads folder based on their file extensions. The module moves files into predefined folders according to a configuration file, making it easier to find and manage your downloaded files.",
"version": "0.1.1",
"split_keywords": [],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "e171fb576a9c7b14f7e5ecd4a152f6b69f37944efef02d3899a348fa7b4b3f1b",
"md5": "1c59ff890a75ea8085ef25e0584211b2",
"sha256": "d198d8328e9fc0724b48446343aabbbba06f871302d96aae9b659d73d549f9a2"
},
"downloads": -1,
"filename": "download_sorter-0.1.1-py3-none-any.whl",
"has_sig": false,
"md5_digest": "1c59ff890a75ea8085ef25e0584211b2",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.8,<4.0",
"size": 3572,
"upload_time": "2023-04-19T23:03:20",
"upload_time_iso_8601": "2023-04-19T23:03:20.031471Z",
"url": "https://files.pythonhosted.org/packages/e1/71/fb576a9c7b14f7e5ecd4a152f6b69f37944efef02d3899a348fa7b4b3f1b/download_sorter-0.1.1-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "1a7e9fa351813c6a19df12c2eeb4783a038a2ed73c177964885a8de4790e94b9",
"md5": "70b66021b89bae1ba2532e262e2c8af2",
"sha256": "7ce5fdf61ca38b238cca87fb476832263ea23cae98802af46a843c403f7da68c"
},
"downloads": -1,
"filename": "download_sorter-0.1.1.tar.gz",
"has_sig": false,
"md5_digest": "70b66021b89bae1ba2532e262e2c8af2",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.8,<4.0",
"size": 2985,
"upload_time": "2023-04-19T23:03:23",
"upload_time_iso_8601": "2023-04-19T23:03:23.418503Z",
"url": "https://files.pythonhosted.org/packages/1a/7e/9fa351813c6a19df12c2eeb4783a038a2ed73c177964885a8de4790e94b9/download_sorter-0.1.1.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2023-04-19 23:03:23",
"github": false,
"gitlab": false,
"bitbucket": false,
"lcname": "download-sorter"
}