A set of miscellaneous Bash shell scripts which are mainly centered around task automation.
chmod +x script_file.sh
./script_file.shAccess help by typing:
./script_file.sh -hor
./script_file.sh --helpCreates a boilerplate Git project repository by executing the following steps:
- Create project directory
- Create recommended subdirectories
- Create license, readme, changelog, and gitignore template files
- Initialize Git repository
The markdown templates are downloaded from the following repositories:
- Licenses: IQAndreas/markdown-licenses - Unlicense
- Readme: me-and-company/readme-template - MIT
- Changelog: olivierlacan/keep-a-changelog - MIT
Currently supported licenses (default: gnu-gpl-v3.0):
- artistic-v2.0, bsd-2, bsd-3, epl-v1.0, gnu-agpl-v3.0, gnu-fdl-v1.3, gnu-gpl-v1.0, gnu-gpl-v2.0, gnu-gpl-v3.0, gnu-lgpl-v2.1, gnu-lgpl-v3.0, mit, mpl-v2.0, unlicense
These can be selected via the -l|--license command line option, such as:
./git_project-init.sh -l mitResets the Unix file-system permissions of files and directories to their system defaults. Multiple path arguments can be passed, and directories are scanned recursively.
Helps the Linux user to automate mounting cloud storages via the rclone command line application. All configuration is handled by the included .conf file. It is recommended to be run as an autostart/start-on-login script (see bellow).
Helps the user to quickly set a script to run automatically on user login.
Performs an automated system cleanup on Linux OSs. The following steps can be executed:
- Cleaning the cache directory
- Emptying the Trash
- Removing older temp and logs files
- Vacuuming the journals
- Clearing the package manager cache
- Checking for orphaned packages
The severity of the cleanup ("normal" or "aggressive" level) can be set by command line arguments (none or -a|--aggressive). Both Arch and Debian versions are available. The script requires sudo privileges to execute all steps properly.
Unifies the different archive extracting commands into a single one for convenient use. Recommended to be copied to /usr/local/bin to make the "extract" command available at all times. This can be done by executing:
./git_project-init.sh -aor
./git_project-init.sh --addCurrently supported archive formats: 7z, bzip2, gzip, rar, tar, xz, zip, zstd.
The coding format of the scripts adhere to the Google Shell Style Guide.
Tested on: CachyOS, GNU bash, 5.3.9(1)-release, and MX Linux 23.5, GNU bash, 5.2.15(1)-release.