7 releases
Uses new Rust 2024
0.2.6 | May 29, 2025 |
---|---|
0.2.4 | May 27, 2025 |
0.1.2 | May 22, 2025 |
#254 in Machine learning
348 downloads per month
28KB
490 lines
nexish
nexish is a simple, experimental shell created as a learning project in Rust.
🚀 Overview
This project is designed primarily for learning and experimentation with:
- Rust's standard library (
std::fs
,std::process
, etc.) - Command-line argument parsing (manual and with crates like
clap
) - File system interaction
- Basic shell design and command implementation
✨ Features
- Basic shell prompt and command loop
- Built-in commands:
ls
,cd
,pwd
,mkdir
,touch
,rmdir
, and more - Manual flag parsing (with plans for
clap
integration) - Directory listing and navigation
- Minimalist and focused on understanding, not production
🛠️ Prerequisites
You need Rust installed.
🖋️ Nerd Font Support (for Icons/Symbols)
Some parts of nexish
use special Unicode symbols and icons (such as device logos) from Nerd Fonts.
For the best experience, configure your terminal to use a Nerd Font. Otherwise, some symbols may appear as squares or question marks.
- How to use Nerd Fonts:
- Download a patched font from Nerd Fonts.
- Set your terminal emulator to use this font (check your terminal's settings/preferences).
- If you do not use a Nerd Font: The shell will still work, but icons/logos may not display properly.
📦 Installation
You have three options: via Cargo, via prebuilt script, or manual install.
🔹 1. Easiest: Install via Cargo (Recommended)
If you have Rust installed, you can install directly from crates.io:
cargo install nexish
This is the most "Rusty" and portable way.
It automatically downloads, compiles, and installs the latest version to your $HOME/.cargo/bin
.
If you want even faster installs with prebuilt binaries, check out cargo-binstall:
cargo binstall nexish
🔹 2. Quick Install via Script
Alternative: Installs the latest release binary to your system PATH.
curl -sSfL https://raw.githubusercontent.com/santoshxshrestha/nexish/main/scripts/install.sh | bash
- This script will:
- Build
nexish
in release mode (if Rust is present). - Copy the binary to
/usr/local/bin
. - Make it executable.
- Build
Tip: You may need to enter your password for
sudo
privileges.
🔹 3. Manual Build & Install
If you prefer full control or want to customize the build:
-
Clone the repository:
git clone https://github.com/santoshxshrestha/nexish.git cd nexish
-
Build the Release Binary:
cargo build --release
This places the binary at
target/release/nexish
. -
Copy to a PATH directory (e.g.,
/usr/local/bin
):sudo cp target/release/nexish /usr/local/bin/nexish
-
(Optional) Ensure executable permission:
sudo chmod +x /usr/local/bin/nexish
-
Run from anywhere:
nexish
🗑️ Uninstallation
You can uninstall using the provided script or manually:
🔹 1. Quick Uninstall via Script
curl -sSfL https://raw.githubusercontent.com/santoshxshrestha/nexish/main/scripts/uninstall.sh | bash
🔹 2. Manual Uninstall
Remove the binary from your PATH:
sudo rm /usr/local/bin/nexish
or
sudo rm /usr/bin/nexish
If you also want to remove your cloned repository:
rm -rf ~/nexish
If installed with Cargo:
cargo uninstall nexish
🖥️ Usage
After installation, start the shell by typing:
nexish
You can use commands like:
ls
cd
pwd
ls -a
mkdir
touch
rmdir
⚠️ Notes
- Learning project: Not all edge cases are handled.
- Not intended for production use.
- Suggestions and contributions are welcome as part of the learning process.
📄 License
Made as a Rust learning exercise. Enjoy exploring!
Dependencies
~17–29MB
~517K SLoC