rembook
rembook is a simple CLI tool that helps you bookmark and manage SSH connections from your bash history. Stop scrolling through .bash_history to find that one server you accessed last week!
Features
- 📚 Automatic History Parsing: Scans your
.bash_historyfor SSH connections - 🔖 Bookmark Management: Save frequently used SSH commands with memorable names
- 🎯 Quick Access: Launch saved connections with a single command
- 📊 Interactive Selection: Browse available connections in a neat table
- 🔢 Smart Sorting: Shows most frequently used connections first
Installation
From PyPI
pip install rembook
From Source
git clone git@github.com:Glucksistemi/rembook.git
cd rembook
pip install -e .
Usage
Basic Usage
Simply run rembook to see an interactive list of all available SSH connections:
rembook
This will display a table with:
- All your bookmarked connections
- SSH commands from your bash history (sorted by frequency)
Select a connection by entering its number, or type a new SSH command directly.
Launch a Saved Bookmark
rembook myserver
This will execute the SSH command associated with the bookmark myserver.
Create a Bookmark
Add a bookmark interactively:
rembook -a
You'll be prompted to select a connection and give it a name.
Or create a bookmark directly:
rembook mybookmark -a
This will prompt you to select a connection to save as mybookmark.
Delete a Bookmark
rembook mybookmark -d
Or delete interactively:
rembook -d
Examples
Example 1: Browse and connect
$ rembook
No Connection Bookmark
-- ---------------------- ----------
1 ssh user@server1.com prod
2 ssh admin@192.168.1.1 router
3 ssh dev@staging.com
Enter number of connection or ssh command [1]: 1
# Connects to server1.com
Example 2: Save a bookmark
$ rembook production -a
No Connection Bookmark
-- ---------------------- ----------
1 ssh user@prod.app.com
2 ssh admin@192.168.1.1 router
Enter number of connection or ssh command [1]: 1
# Saves ssh user@prod.app.com as "production"
Example 3: Use a saved bookmark
$ rembook production
# Immediately connects to ssh user@prod.app.com
Example 4: Quick SSH with custom command
$ rembook
No Connection Bookmark
-- ---------------------- ----------
1 ssh user@server1.com prod
Enter number of connection or ssh command [1]: user@newserver.com
# Connects to ssh user@newserver.com
How It Works
- History Parsing: rembook scans your
~/.bash_historyfile for SSH commands - Frequency Analysis: Commands are ranked by how often you've used them
- Persistent Bookmarks: Saved bookmarks are stored in your user config directory
- Quick Execution: Selected commands are executed directly via
os.system()
Requirements
- Python 3.10+
- Bash shell (uses
.bash_history) - Linux or macOS
Dependencies
Configuration
Bookmarks are stored in a JSON file at:
- Linux:
~/.config/rembook/bookmarks.json - macOS:
~/Library/Application Support/rembook/bookmarks.json
License
BSD 3-Clause License. See LICENSE file for details.
Author
Kirill Nikolsky - glucksistemi@gmail.com
Contributing
Contributions are welcome! Please feel free to submit a Pull Request.
Repository
Metadata
Release files for rembook 0.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| rembook-0.1.0.tar.gz | 6.0 kB | Without provenance | Details for rembook-0.1.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| rembook-0.1.0-py3-none-any.whl | Python 3 | none | any | Details for rembook-0.1.0-py3-none-any.whl |
Total release size: 12.5 kB
Release files / rembook-0.1.0.tar.gz
| Download URL | rembook-0.1.0.tar.gz |
|---|---|
| Size | 6.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
01af135c1681b8fd4ac4cf6ce0e8256c79a5bd188e2838086fdb7d295fa0c6b9
|
|
BLAKE2b-256 checksum How to use checksums |
3471355b29e395d27151f12e0467beff32cb6b8ba66a772ebbe77c068e2e7b44
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.10.12
|
Release files / rembook-0.1.0-py3-none-any.whl
| Download URL | rembook-0.1.0-py3-none-any.whl |
|---|---|
| Size | 6.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
60e5292cd755fb6b2254c3bdb4549ee6478b8a82b4c0b8b8a43962d4d8042ce8
|
|
BLAKE2b-256 checksum How to use checksums |
62634b05459c9805ab363e8b5e6b7ccb356c27ffa8f3cbeadf7d953325fd7ac3
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.10.12
|
Security for rembook 0.1.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.