ShellSketch is a versatile robust bash script template, with the aim of generating structred-formatted shell scripts as preference by user selection through automation without manually creating scripts from scratch. It is also a customizable tool that offers the control of how you want to format your shell scripts.
ShellSketch offers series of features designed to automate shell and bash scripting:
ShellSketch offers support for implementing documentation structure for headers and functions to provide readability and maintainability. It includes fields for a detailed description, notes and a list of required dependencies, ensuring comprehensive project documentation.
ShellSketch offers a list of extensive license types from GitHub itself that allow you the selection of specifying the appropriate license for your project, listed under the following:
License | Description |
---|---|
Apache-2.0 | Apache License 2.0 |
GPL-3.0 | GNU General Public License v3.0 |
MIT | MIT License |
BSD-2-Clause | BSD 2-clause 'simplified' license |
BSD-3-Clause | BSD 3-clause 'New' or 'Revised' license |
BSL-1.0 | Boost Software License 1.0 |
CC0-1.0 | Creative Commons Zero v1.0 Universal |
EPL-2.0 | Eclipse Public License 2.0 |
AGPL-3.0 | GNU Affero General Public License v3.0 |
LGPL-2.1 | GNU Lesser General Public License v2.1 |
MPL-2.0 | Mozilla Public License 2.0 |
Unlicense | The Unlicense |
ShellSketch supports Custom ANSI Escape Sequences to display colors in shell scripts during development, ideal for improving user experience through visual output.
Furthermore, it supports Custom Log Level Messaging which provide predefined log levels (INFO, SUCCESS, WARNING, ERROR) to clarify script output messages, which can be customized for better visual output.
ShellSketch supports the creation of customized CLI menu that allow for the creation of customized command-line interface menus to make your scripts interactive. This also involves generating USAGE and HELP functions to produce your scripts effectively.
ShellSketch supports GUI mode which uses YAD (Yet Another Dialog) that displays GTK+ dialog boxes and Whiptail for usability and accessability of inputting values through simple user interface, which Whiptail is included by default on Debian.
YAD (Yet Another Dialog)
Whiptail
It is highly recommended that you run this script on Debian or Debian-based distribution machine (Ubuntu, Linux Mint, Zorin OS or Kali Linux) to avoid compatibility and software issues since packages are installed from the default package manager of Debian apt.
Interacting with ShellSketch in GUI mode through requires the installation of YAD and Whiptail using apt package manager, which can be performed by executing the following commands:
sudo apt-get install whiptail
sudo apt-get install yad
# OR
sudo apt-get install whiptail yad
# Clone the following repository
git clone https://github.com/eliaz5536/ShellSketch
# Change directory to repository folder and modify file permission to be executable
cd ShellSketch
chmod +x template.sh
# Execute the script
./template.sh -h
ShellSketch - Blueprint Shell Script Template Generator
Usage: ./template.sh [mode] [options]
ShellSketch - Blueprint Shell Script Template Generator
Usage: ./template.sh [mode] [options]
Options:
--usage Show usage information
-h, --help Show help message
-n, --name <FILE_NAME> Specify script file name
-t, --title <SCRIPT_TITLE> Specify official title of the script
-a, --author <AUTHOR> Specify name of the author
-d, --description <DESCRIPTION> Specify description
-ns, --notes <NOTES> Specify notes
-dp, --dependencies <DEPENDENCIES> Specify required dependencies
-l, --license <LICENSE_TYPE> Specify license type
ANSI Color Code Options:
-c, --colors <STANDARD_COLORS> Specify standard ANSI color code escape sequences
-ac, --all-colors Implement all standard ANSI color code escape sequences
-bgc, --bg-colors <BACKGROUND_COLORS> Specify background ANSI color code escape sequences
-abgc, --all-bg-colors Implement all background ANSI color code escape sequences
-ic, --italic-colors <ITALIC_COLORS> Specify italic ANSI color code escape sequences
-aic, --all-italic-colors Implement all italic ANSI color code escape sequences
-boc, --bold-colors <BOLD_COLORS> Specify bold ANSI color code escape sequences
-aboc, --all-bold-colors Implement all bold ANSI color code escape sequences
Font Options:
-fs, --font-styles <FONT_STYLES> Specify ANSI font style color code escape sequences
-afs, --all-font-styles Implement all font styles (BOLD & ITALIC)
Message Options:
-mt, --message-types <LOG_MESSAGE_TYPES> Specify log message types
--show-messages Display a list of messages as functions to use in script
Command-Line Interface Option:
-cli, --command-line-interface Implements Command-Line interface (USAGE, HELP & parsing argument menu)
Mode:
gui Enters GUI mode (Whiptail)
Help Options:
--licenses Show list of license types
--show-ansi Show list of available ANSI escape sequences
Other:
--all Implement all features (all ANSI escape sequences, message functions and CLI)
This project is licensed under the GNU General Public License v3.0. See the LICENSE file for details.