High-performance Rust utilities for system administration and development workflows.
Rust Utils provides a suite of fast, reliable command-line tools designed to streamline common system administration and development tasks. Built with Rust's performance and safety guarantees, these utilities offer memory-safe alternatives to traditional system tools.
Key Features:
- 🚀 High Performance: Rust's zero-cost abstractions for maximum speed
- 🔒 Memory Safety: No segfaults or buffer overflows
- 🔧 Cross-Platform: Works on all Unix-like systems
- ⚡ Extensible: Easy to add new utilities and commands
git clone https://github.com/dgalbraith/rust-utils.git
cd rust-utils
cargo build --release
sudo cp target/release/rust-utils /usr/local/bin/d
cargo install rust-utils# Install from source
git clone https://github.com/dgalbraith/rust-utils.git
cd rust-utils && cargo install --path .
# Basic usage - preview UID/GID remapping
rust-utils remap /path/to/directory \
--from-base 100000 --to-base 50000000 --dry-run
# Perform the actual remapping
rust-utils remap /path/to/directory \
--from-base 100000 --to-base 50000000| Command | Description | Documentation |
|---|---|---|
remap |
UID/GID filesystem remapping | Command Reference |
- 📖 Command Reference - Complete command documentation
- 🚀 Examples - Real-world usage examples
- 💻 Development - Building and contributing
- 🧪 Testing - Comprehensive test coverage
- 🤝 Contributing - Contribution guidelines and setup
- 📋 Changelog - Version history and release notes
- Container Migration: Move containers between hosts with different ID mappings
- Privilege Conversion: Convert privileged containers to unprivileged
- System Administration: Bulk UID/GID changes for system maintenance
- Development: Test applications with different user namespace configurations
These Rust utilities offer significant performance improvements over traditional shell scripts and Python alternatives:
- ~3-10x faster processing due to compiled nature and efficient algorithms
- Lower memory usage with efficient data structures and zero-copy operations
- Better error handling with Result types and proper error propagation
- Safe concurrency potential for future parallel processing features
- Rust 1.70+ (2021 edition)
- Unix-like system with standard filesystem utilities
# Development build
cargo build
# Release build with optimizations
cargo build --release
# Run tests
cargo test
# Check code with clippy
cargo clippy
# Format code
cargo fmtsrc/
├── main.rs # Application entry point
├── lib.rs # Library root
├── cli.rs # Command-line interface
├── error.rs # Error types and handling
├── fs.rs # Filesystem utilities
└── commands/
├── mod.rs # Commands module
└── remap.rs # Remap command implementation
Set the RUST_LOG environment variable to control logging:
# Enable debug logging
RUST_LOG=debug rust-utils remap ...
# Enable info logging (default)
RUST_LOG=info rust-utils remap ...
# Enable trace logging (very verbose)
RUST_LOG=trace rust-utils remap ...We welcome contributions! Please see CONTRIBUTING.md for detailed guidelines on:
- Setting up the development environment
- Code quality standards and testing requirements
- Commit message conventions
- Pull request process
- Adding new features and commands
This project is licensed under the MIT License - see the LICENSE file for details.
- Rust community for excellent tooling and libraries
- System administrators who inspired these utilities
- Open source contributors and maintainers