51 lines
1.5 KiB
Markdown
51 lines
1.5 KiB
Markdown
# Perl Shell (pshell)
|
|
|
|
A modular Perl shell with SQLite command history and environment variables.
|
|
|
|
## Notes
|
|
|
|
No job control, but that is what programs like tmux are for anyway. Fairly, basic shell, but modular. This does depend on some modules. Also still a work in progress.
|
|
|
|
## Why did I create this?
|
|
|
|
This was created entirely on a whim. I just want to get back to some Perl coding and see what crazy thing I can do. Turns out this is the result. Oddly, enough I will likely end up using this as my normal shell. Its not anything super shiny or amazing, but it does the basics the way I want it to. Especially the history without needing to add something like atuin.
|
|
|
|
## Dependencies
|
|
|
|
- DBI
|
|
- DBD::SQLite
|
|
- Term::ReadLine
|
|
- Cwd
|
|
- File::HomeDir
|
|
- Environment::SQLite (for environment variables, part of the source, listed for completeness)
|
|
- History::SQLite (for command history, part of the source, listed for completeness)
|
|
|
|
If they are not marked as part of the source for the shell, you will need to install them manually. Via cpan or your package manager.
|
|
|
|
## Features
|
|
|
|
- Executes shell commands
|
|
- Logs all commands to SQLite database
|
|
- Stores environment variables in SQLite database
|
|
- Modular design for easy extension
|
|
|
|
## Installation
|
|
|
|
1. Install dependencies(recommended way):
|
|
```
|
|
cpanm --installdeps .
|
|
```
|
|
|
|
2. Make the shell executable:
|
|
```
|
|
chmod +x pshell.pl
|
|
```
|
|
|
|
3. Run the shell:
|
|
```
|
|
./pshell.pl
|
|
```
|
|
|
|
## Usage
|
|
|
|
Run it and treat it as a shell.
|