abelith 80a90b65bb chore: sql builder instead of row sql
feat: extensive search queries
2026-08-15 13:51:15 +05:00
fix
2026-08-14 19:14:18 +05:00
2026-08-04 01:16:32 +05:00
2026-08-03 04:13:35 +05:00
fix
2026-08-14 19:14:18 +05:00
2026-08-15 13:51:15 +05:00
2026-08-15 13:51:15 +05:00
2026-08-04 01:47:26 +05:00
fix
2026-08-14 19:14:18 +05:00

spellbook 0.2.1-alpha

spellbook is a lightweight CLI command manager written in Go. It allows you to save complex shell commands as parameterized templates ("spells") and execute them instantly with custom arguments.


Table of contents


Features

  • Pure Go & CGO-Free: Built with SQLite (modernc.org/sqlite), resulting in a single portable binary without external dependencies.
  • Templating: Define dynamic parameters inside commands using {{ .variable }} syntax.
  • Tags & Descriptions: Organize and document your command collection.

Building from Source

Prerequisites

  • Go 1.22 or higher

Build Steps

# Clone the repository
git clone https://github.com/abelith/spellbook.git
cd spellbook

# Build static binary
CGO_ENABLED=0 go build -o spellbook .

# Move to bin directory (for Linux/macOS)
mv spellbook $(go env GOPATH)/bin/

Configuration

Env

  • SPELLBOOK_DB_PATH: db location (example: /spellbook/spellbook.db)

Usage

  • Use spellbook help to list commands
  • Use spellbook [command] --help to get info on specific command

List spells

Use spellbook to list prepared spells

Add new spell

Use spellbook add -n name -t tags -d desc -- command to add a new spell

  • -n or --name is a name of a spell
  • -t or --tags is a comma-separated list of spell tags
  • -d or --desc is a short description of spell
  • command is an actual spell template

Remove a spell

Use spellbook rm [spell_name] to remove a spell

  • spell_name is a name of a spell

Casting a spell

Use spellbook [spell_name] key=val to cast a spell

  • spell_name is a name of a spell
  • key=val are key/value arguments

Examples

Said, you have added a spell like this

spellbook add -n my-spell -t net,http -d my-desc -- curl 127.0.0.1

To use it, run this command

spellbook my-spell

Or you may want to use dynamic parameters like this

spellbook add -n my-spell -t net,http -d my-desc -- curl {{.target}}

And cast the spell like this

spellbook my-spell target=127.0.0.1

Upcoming Features

  • Search to navigate your spell book
  • Export/import spellbooks
S
Description
No description provided
Readme
84 KiB
0 Stars 1 Watchers 0 Forks
Languages
Go 100%