s3sh - The S3 Shell
Overview
s3sh is an interactive S3 shell for exploring Amazon S3 buckets with Unix-like commands. Navigate S3 buckets and prefixes like directories, and seamlessly explore archive contents (tar, tar.gz, tar.bz2, zip) without downloading entire files.
Key Features
- Unix-like Commands - Use familiar
ls,cd,cat,pwdcommands to navigate S3 - Archive Navigation -
cddirectly into tar/zip files and explore their contents - Efficient Streaming - Uses S3 range requests to access archive contents without full downloads
- Interactive Shell - Full command history and line editing via rustyline
Installation
Available via crates.io:
Or build from source:
Usage
Launch the interactive shell:
Basic Commands
Navigate S3 like a filesystem:
# List buckets at root
# Navigate into a bucket
# List objects and prefixes
# Navigate through prefixes
# View file contents
# Show current location
Archive Navigation
Explore archives without downloading:
# Navigate into an archive
# List archive contents
# Navigate within the archive
# View files from inside archives
Tab Completion
Smart completion based on context:
# Tab completes bucket names
# Tab completes objects and prefixes
# cd only shows directories
# cat shows all files
## Supported Archive Formats
## AWS Credentials
)
)
)
Technical Details
Architecture
- VFS Abstraction - Unified virtual filesystem for S3 objects and archive entries
- Lazy Archive Indexing - Archives are indexed on first access and cached
- S3 Range Requests - Efficient random access to archive contents
- Async Runtime - Built on Tokio for concurrent S3 operations
Performance
- LRU Caching - Archive indexes are cached to avoid repeated S3 calls
- Streaming - Large files are streamed, not loaded into memory
- Parallel Listings - Tab completion fetches directory contents on-demand
Contributing
Contributions are welcome! Please feel free to submit issues or pull requests.
License
MIT License - see LICENSE file for details
Related Projects
- s3grep - Fast parallel grep for S3 buckets