Skip to content

FelineFantasy/ask_input

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

simple_input ⌨️

Rust Version License

A micro-library for simple keyboard input in Rust. No extra code — just input and get values!

📋 Table of Contents

📝 Description

simple_input is a tiny wrapper library over Rust's standard I/O. It allows you to easily get numbers and strings from users without writing verbose boilerplate code every time.

Features:

  • 🎯 Minimalism — Only 3 functions for everything
  • 🔄 Ready to use — Parses and returns data immediately
  • 📦 Lightweight — Zero extra dependencies
  • 🔌 Simple integration — Add to Cargo.toml and go

🎮 How to Use

  1. Add the library to your project
  2. Call the desired input function
  3. Use the received value

⚙️ Installation

Option 1: Add to Cargo.toml manually

[dependencies]
simple_input = { git = "https://github.com/FelineFantasy/ask_input.git" }

Option 2: Clone the repository

git clone https://github.com/FelineFantasy/ask_input.git

🧪 Examples

use simple_input;

let number = simple_input::get_number::<i32>();
let text = simple_input::get_string();

📦 Functions

  • get_number<T>() — Gets a number of type T from input
  • get_string() — Gets a string from input
  • get_number_range<T>(min, max) — Gets a number within a range

📋 Requirements

  • Rust 1.70+
  • Cargo

👤 Author

FelineFantasy

License: MIT

About

Micro-library for simple keyboard input in Rust

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages