Skip to content
imsudoerPublic

About

Modular bash dashboard, MOTD and shell-augmentation framework for VDS - turn your SSH login into a control center

Topics

Resources

Stars

3 stars

Watchers

0 watching

Forks

Latest commit

 

History

10 Commits

Folders and files

Repository files navigation

Bashboard

Modular bash dashboard, MOTD, and shell-augmentation framework

Turn your SSH login into a control center.

Shell Platform License Status

Warning

AI-Generated Documentation

This entire documentation was generated by an AI assistant using the complete project source code as context. While every effort was made to ensure accuracy, some details may be outdated, imprecise, or contain subtle errors.

Found an issue? Please open an issue or submit a pull request.


What it does

Bashboard is a lightweight, fully-modular bash framework that replaces your boring MOTD with an interactive control center, augments your shell with productivity tools, and tracks your server's life like a game. Zero external dependencies beyond standard Linux utilities.

 ____        _       _____
/ __ \      | |     / ____|
| |  | |_ __| |_   | (___   __ _
| |  | | '_ \| | | | |\___ \ / _` |
| |__| | | | | | |_| |____) | (_| |
 \____/|_| |_|_|\__, |_____/ \__, |
                 __/ |          | |
                |___/           |_|

Features

Welcome dashboard

  • Three interface modes: plain MOTD / interactive slides menu / full TUI
  • 11+ built-in modules: host info, network, resources, SSL certs, systemd services, Docker, security, updates, top processes, and more
  • Progress bars and ASCII graphs for CPU/RAM/disk
  • Per-module toggles via a single config file
  • Theming with accent color and panel backgrounds

Gamification

  • Login streak tracking (current + record)
  • Uptime records with new-record celebrations
  • Server age — how long since your VDS was born
  • Achievements — unlock badges for uptime/streak/age milestones

Shell augmentation

  • al — alias manager with templated arguments (al "systemctl {1} {2}" sysctl)
  • chain — named command pipelines with step-by-step confirmation
  • helpme — interactive help center, also servable over HTTP
  • cfg — quick-edit registered config files (cfg nginx, cfg ssh)
  • f — fast file finder by name / content / age
  • env-check — verify presence of tool sets (env-check py)
  • redo — re-run last command with modifications
  • watch-reload — re-run a command on file change
  • remember — persistent environment variables across sessions
  • peek — colorized JSON viewer (no jq required)
  • qr — QR codes in terminal
  • serve — quick HTTP server for current directory
  • svc — interactive systemd service manager
  • note — quick note-taking with timestamps
  • Bookmarks — bookmark name / go name for instant directory jumps
  • Ctrl+G — context-aware menu (changes based on git/docker/npm/etc)

Smart prompt

  • Breadcrumbs showing project root and relative path
  • Git integration — branch, dirty state, ahead/behind upstream
  • Last command duration — flagged when > 3 seconds
  • Exit code coloring on prompt arrow

Per-project history

  • Each git repository gets its own bash history
  • Auto-switches when you cd between projects
  • Mark any directory as a project with projhist mark

Safety

  • Extended safe-rm — confirms rm -rf, dangerous chmod, dd, mkfs, chown on system paths, iptables -F
  • Three confirmation levels — yes/no, type 'yes', random code

Install

git clone https://github.com/imsudoer/bashboard ~/.sutd
~/.sutd/install.sh
exec bash

Or copy the directory manually and append to ~/.bashrc:

if [ "$PS1" ] && [ -x ~/.sutd/motd.sh ]; then
    ~/.sutd/motd.sh
fi

for f in ~/.sutd/terminal/*.sh; do
    [ -r "$f" ] && source "$f"
done

Requirements

  • Bash 5.0+ (for EPOCHREALTIME)
  • Linux with systemd (for service modules)
  • coreutils, findutils, gawk, procps, iproute2 — usually pre-installed
  • Optional: openssl (SSL module), inotify-tools (watch-reload), qrencode (QR), python3 (peek, serve, helpme -w)

Configuration

Everything is configured via ~/.sutd/info.conf:

# Interface mode: 0=plain MOTD, 1=slides menu, 2=full TUI
INTERFACE_MODE=1

# Theme
THEME_ACCENT="208"          # 256-color code (208=orange, 75=blue, 141=purple)
THEME_BG="237"              # background color for panels
THEME_BG_ENABLED=1

# Modules — enable/disable each
ENABLE_HOST=1
ENABLE_NETWORK=1
ENABLE_RESOURCES=1
ENABLE_SSL_CERTS=1
ENABLE_TOP_PROCESSES=1
ENABLE_ACHIEVEMENTS=1
# ... etc

# Module-specific
SSL_WARN_DAYS=14
TOP_PROCESSES_COUNT=3
LAST_COMMANDS_COUNT=5
SHOW_WEATHER_CITY="Moscow"

# Safety
SAFE_RM_LEVEL=2             # 1=y/n, 2=type 'yes', 3=random code

# Key bindings
CTX_MENU_BIND="\C-g"        # Ctrl+G opens context menu

# Helpme web server
HELPME_PORT=8765
HELPME_BIND="127.0.0.1"     # set to 0.0.0.0 to expose

Directory layout

~/.sutd/
├── motd.sh                 # main entry point
├── menu.sh                 # slides interface
├── lib.sh                  # shared helpers
├── info.conf               # main config
├── services.list           # systemd services to monitor
├── modules/                # dashboard modules (numbered for order)
│   ├── 10-host.sh
│   ├── 20-network.sh
│   ├── 30-system.sh
│   ├── 40-resources.sh
│   ├── 45-ssl-certs.sh
│   ├── 46-top-processes.sh
│   ├── 47-streak.sh
│   ├── 48-uptime-record.sh
│   ├── 49-server-age.sh
│   ├── 50-services.sh
│   ├── 51-achievements.sh
│   ├── 52-progress-bars.sh
│   ├── 53-ascii-graph.sh
│   ├── 60-docker.sh
│   ├── 70-security.sh
│   ├── 80-updates.sh
│   └── 95-last-commands.sh
├── terminal/               # shell-injected utilities
│   ├── prompt.sh
│   ├── mods.sh
│   ├── safe-rm.sh
│   ├── al.sh
│   ├── chain.sh
│   ├── helpme.sh
│   ├── cfg.sh
│   ├── f.sh
│   ├── env-check.sh
│   ├── redo.sh
│   ├── watch-reload.sh
│   ├── remember.sh
│   ├── peek.sh
│   ├── qr.sh
│   ├── serve.sh
│   ├── stats.sh
│   ├── ctx-menu.sh
│   ├── proj-history.sh
│   └── tui.sh
└── data/                   # state, histories, achievements
    ├── streak.dat
    ├── uptime_record.dat
    ├── achievements.dat
    ├── install_date.dat
    ├── notes.txt
    ├── aliases.dat
    ├── chains/
    ├── helpme/
    ├── env-checks/
    ├── proj_histories/
    └── remembered.dat

Writing your own module

Create ~/.sutd/modules/55-myhealth.sh:

#!/bin/bash

divider
section "My Health Check:"

field "API" "$(curl -s -o /dev/null -w '%{http_code}' https://api.example.com)"
field "DB"  "$(pg_isready -h db.local && echo OK || echo DOWN)"

Enable it in info.conf:

ENABLE_MYHEALTH=1

The module loader strips the numeric prefix, uppercases the rest, and looks for ENABLE_<NAME>=1. Modules run in filename order.

Available helpers when your module is loaded:

Helper Purpose
field k v print aligned key-value row
section "..." print section title
divider print horizontal rule
get_cpu_usage reliable CPU percentage from /proc/stat
is_int x validate integer
$COLOR_ACCENT theme accent (orange by default)
$COLOR_* green/red/yellow/gray/etc
$SUTD_DIR path to ~/.sutd

Commands reference

Navigation

..              cd ..
....            cd ../../..
mkcd <dir>      mkdir + cd
bookmark <name> save current dir
go <name>       jump to bookmark
go              list bookmarks

Alias manager

al "<cmd>" <name>           save
al <name>                   run
al <name> arg1 arg2         run with {1}, {2} substitution
al <name> -e                edit
al <name> -d                delete
al -s <pattern>             search

Command chains

chain new <name>
chain add <name> "<cmd>"
chain run <name>            run all
chain run <name> -c         confirm each step
chain show <name>
chain edit <name>

Help system

helpme                      browse topics interactively
helpme <topic>              show specific page
helpme -w [port]            serve over HTTP
?                           short alias for helpme

Files & search

f <pattern>                 find by name
f -c "<text>"               grep content
f -d 1                      modified in last day
f -t f|d                    type filter
extract <archive>           unpack any archive
backup <file>               timestamped copy
bigfiles [n]                top large files
peek <file.json>            colorized JSON

System

serve [-p port] [-i ip]     quick HTTP server
svc                         systemd service menu
env-check <preset>          verify tool installation
cfg <name>                  edit registered config
watch-reload <f> "<cmd>"    re-run on change
ports                       open listening ports
myip                        local + public IP
weather [city]              wttr.in
qr "<text>"                 QR code in terminal

Notes & memory

note "<text>"               add note
note                        list
note -d <n>                 delete note #n
remember KEY=value          persist env var
remember                    list remembered

Project history

projhist                    list project histories
projhist mark               mark current dir as project
projhist current            show active project

Replay

redo                        repeat last command
redo arg                    last command + new arg
redo s/old/new/             sed replace in last
hgrep <pattern>             search history
hrun <pattern>              run last matching command

Keybindings

Key Action
Ctrl+G Context menu (project-aware)
←/→ Navigate slides (menu mode)
↑/↓ Navigate slides (TUI mode)
q Exit menu/TUI to plain shell
h Help (in menu mode)
m Switch TUI → menu mode
r Refresh current slide (TUI mode)

Theming

Pick a 256-color code from any xterm color chart:

# Classic orange (default)
THEME_ACCENT="208"
THEME_BG="237"

# Matrix
THEME_ACCENT="46"
THEME_BG="234"

# Ocean
THEME_ACCENT="75"
THEME_BG="236"

# Cyber pink
THEME_ACCENT="201"
THEME_BG="235"

# No background panels
THEME_BG_ENABLED=0

Performance

A full MOTD render with all modules enabled costs roughly 0.4–1.0 seconds on a typical VDS. Heaviest contributors:

  • top-processes.sh — ~150ms
  • ssl-certs.sh — depends on cert count
  • docker.sh — ~200ms if many containers
  • updates.sh — fast (reads a cached file)

To minimize login time on slow boxes, set INTERFACE_MODE=0 and disable heavy modules in info.conf.

FAQ

Why does my prompt look like garbage with numbers? You probably have an old broken PS1 from before properly escaping $$ $$. Open a new shell with exec bash — the new prompt.sh uses single-quoted PS1 and is safe.

Can I use this without being root? Yes. Some modules (SSL certs, fail2ban, ufw) need either root or passwordless sudo. Set this up in /etc/sudoers.d/bashboard if needed.

Will it work on macOS? Partially. Most shell utilities work. MOTD modules using /proc, systemctl, and apt will not.

How do I disable per-project history? Don't source terminal/proj-history.sh, or remove the file.

Ctrl+G conflicts with my workflow. Change CTX_MENU_BIND in info.conf to anything readline accepts: "\C-o" (Ctrl+O), "\eq" (Alt+Q), "\C-x\C-m", etc.

Roadmap

  • One-line installer with detection and dependency check
  • Telegram notification integration (notify "...")
  • Plugin repository for community modules
  • More achievements (commit-based, command-based)
  • Optional ble.sh integration for fish-like autosuggestions
  • Backup status module
  • Bandwidth tracking via vnstat

Credits

Crafted for onlysq infrastructure. Built entirely in bash because sometimes the best tool is the one already installed.

About

Modular bash dashboard, MOTD and shell-augmentation framework for VDS - turn your SSH login into a control center

Topics

Resources

Stars

3 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages