Move files from deep subdirectories into single folder. For example you have a bunch of files in messy directories:
abyssal_dir
│
├── subdir0
│ ├── subdir00
│ │ ├── file21.ext
│ │ ├── file22.ext
│ │ └── file23.ext
│ └── subdir01
│ ├── file21.ext
│ ├── file22.ext
│ └── file23.ext
│
├── subdir1
│ ├── file21.ext
│ ├── file22.ext
│ └── file23.ext
│
├── subdirn
│
└── file_n.ext
The files are moved to folder called files from abyss which will created automatically where the script or program executed if it not available.
project_dir
│
├── files from abyss
├── other stuffs
└── AFP.exe or abyss.py
- Download the app from the release page.
- Launch the AFP.exe
- Wait a couple second, file explorer will open automatically
- Select the abyssal_dir
- Moving process will started after abyssal_dir selected
Pull_From_Abyss(abyssal_dir, extension = 'all')
extension can not be defined if using AFP.exe, so it would moves all found files
Argument | Type | description |
---|---|---|
abyssal_dir | str | Files parent directory |
extension | str | Files extension \n default: 'all' |
for example the project directory is like this:
project_dir
│
├── data
│ ├── images
│ │ ├── car.jpg
│ │ ├── bike.jpg
│ │ └── bird.jpg
│ └── doc
│ ├── report.pdf
│ └── guide.pdf
│
└── script
from abyss import Pull_From_Abyss
abyssal_dir = '../project_dir/data/'
Pull_From_Abyss(abysall_dir, 'jpg')
This code will move all files ended with jpg to files from abyss, so the result would be like:
project_dir
│
├── files from abyss
│ ├── car.jpg
│ ├── bike.jpg
│ └── bird.jpg
│
├── data
│ ├── images
│ └── doc
│ ├── report.pdf
│ └── guide.pdf
│
└── script
from abyss import Pull_From_Abyss
abyssal_dir = '../project_dir/data/'
Pull_From_Abyss(abysall_dir)
This code will move all files to files from abyss, so the result would be like:
project_dir
│
├── files from abyss
│ ├── car.jpg
│ ├── bike.jpg
│ ├── bird.jpg
│ ├── report.pdf
│ └── guide.pdf
│
├── data
│ ├── images
│ └── doc
│
└── script
The origin directory will remain empty after operation.