/system-tools

place to store py scripts, solving different system tasks.

Primary LanguagePython

system-tools

place to store py scripts, solving different system tasks.

Make it Flat

Destroy directory tree and move all files to top directory.

Sort directory

This script is dedicated to sort directory by chosen extensions.
Example: sortdir audio=.flac,.wav,.mp3 arcs=.zip,.rar docs=.docx, .docx,.pdf

Also it has optional argument -wd. It can be places anywhere.
So it forces script to walk through whole directory tree, not only current working directory.

So this utility takes different number of arguments, where left is name of directory and right values
are extension, that will be moved into mentioned directories. Directories are created from current working directory.

FRD(find and rename duplicates)

Purpose of this script is obvious, but it was written to avoid problems, that may occur when you use directory sorting
script, because there may be files with the same names, but placed in different directories, so some files will not be moved.
To avoid this problem simply use this tiny script.

CGI(create gitignore)

This script is used to create .gitignore file.
Example: cgi -f .sln .txt .user .filter -d Release .git After` -f mark you pass file extensions to add to gitignore and
after ```-d``` mark you pass directories to ignore.

To walk through whole directory of project, you should use -wd option.

SRM(safe rm)

This script rewrites files n times(default value is 5) and then removes it. There will be ability to recover it, but its content will be noise.
Example:
srm kitten.png 100
srm kitten.png

Merger(directory merging script)

This script compares two directories and find files with the same name. Then it walks through list of all matched files and asks user to find out should they be merged.
Example:
merger dir1 dir2
merger dir1 dir2 wd