Skip to content

tome

A set of tools to organize, share & run scripts


What can tome do?


Install

Create and activate a virtual environment. For detailed instructions, refer to the install guide. Then, install tome using pip:

pip install tomescripts 🎉 Tome installed. tome --version 0.1.0

Hello world in 30 seconds

Use tome new to create a template for a command. Then install it in editable mode. Now your changes are reloaded instantly. Afterwards, list all available commands and run it.

# create a new command
$ tome new greetings:hello

# install in editable mode
$ tome install . -e

# list installed commands
$ tome list

📖 /some/path/my-tome

  🌲 greetings commands
     greetings:hello (e)  Description of the command.

# run it!
$ tome greetings:hello Hello!
 ________
< Hello! >
 --------
        \\   @..@
         \\ (----)
           ( >__< )
           ^^ ~~ ^^

Install the examples from a third party, in this case the tome repository:

# install tome examples from the github repository
$ tome install https://github.com/jfrog/tome.git --folder=examples

# list installed commands
$ tome list

📖 https://github.com/jfrog/tome.git

  🌐 network commands
     network:ping-bat            Script to ping an IP address or URL...
     network:ping-sh             Script to ping an IP address or URL...
     network:traceroute-bat      Script to perform a traceroute to an IP address or URL...
     network:traceroute-sh       Script to perform a traceroute to an IP address or URL...

  🖥️  system commands
     system:monitor              Monitor system usage including CPU, memory, and disk.

  🐮 utils commands
     utils:todo                  A simple command-line To-Do list manager.

# ask for help
$ tome system:monitor --help
usage: tome monitor [-h] [-v] [-q] [--cpu] [--memory] [--disk]

Monitor system usage including CPU, memory, and disk.

options:
  -h, --help     show this help message and exit
  -v, --verbose  Increase the level of verbosity (use -v, -vv, -vvv, etc.)
  -q, --quiet    Reduce the output to a minimum, showing only critical errors
  --cpu          Monitor CPU usage in real-time
  --memory       Monitor memory usage in real-time
  --disk         Display disk usage

# run the command
$ tome system:monitor --cpu --memory --disk
Disk Usage: 1.5% used
Total: 926.35 GB
Used: 10.47 GB
Free: 695.70 GB
CPU Usage: 19.1%
Memory Usage: 60.5%
Total: 36.00 GB
Used: 14.75 GB
Available: 14.24 GB
Free: 2.00 GB

What's Next?

Goal Documentation
🚀 Get started in 5 minutes Quickstart
📚 Explore all CLI commands CLI Reference
Contribute or get support Contribution Guide in GitHub