Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/felko/sluggo
Smart shell that can handle mutliple REPLs
https://github.com/felko/sluggo
repl shell terminal
Last synced: about 1 month ago
JSON representation
Smart shell that can handle mutliple REPLs
- Host: GitHub
- URL: https://github.com/felko/sluggo
- Owner: felko
- License: mit
- Created: 2016-10-20T18:24:49.000Z (about 8 years ago)
- Default Branch: master
- Last Pushed: 2016-10-22T00:35:50.000Z (about 8 years ago)
- Last Synced: 2024-08-16T16:22:48.232Z (5 months ago)
- Topics: repl, shell, terminal
- Language: Python
- Size: 21.5 KB
- Stars: 13
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
sluggo
======sluggo is a shell that can handle multiple REPLs.
It provides a few REPLs implementations, including
a git REPL, a Python REPL, and a general command
REPL.## Demo
[![asciicast](https://asciinema.org/a/8i56cd2twd96r9xpxwp4m6saf.png)](https://asciinema.org/a/8i56cd2twd96r9xpxwp4m6saf)
## Features
sluggo features a few basic commands that allow you
to switch between REPLs:- `!go [repl]`: switch to the specified REPL
- `@[repl] [cmd]`: executes the command from the specified REPL
- `$[cmd]`: executes a system command
- `!open [repl]`: opens a REPL session without switching
- `!close [repl]`: closes the specified REPL
- `!alias [name] [cmd]`: Creates an alias to a command that can be called with `![name]`
- `!quit`: closes the current one if no argument is given
- `!exit`: exits sluggo
- `!cls`: clears the console
- `!reload`: reloads the configuration file and the plugins## Modularity
sluggo is extensible. That means you can define your
own REPLs easily:```python
import sluggoclass parrot(sluggo.REPL):
def eval(self, input):
print(input)
```You just need to put this in your ~/.sluggo/plugins directory for it to be
loaded automatically:```bash
$ !go parrot
parrot> hey
hey
parrot> it's annoying
it's annoying
```