1 unstable release
0.1.0 | Apr 29, 2022 |
---|
#9 in #ctrl-c
4KB
Description
A simple easy to use wrapper around Ctrl-C signal.
Example usage
use anyhow::{Context, Result, Ok};
use block_until_sigint::block;
#[tokio::main]
async fn main() -> Result<()> {
block(async {
println!("Hello, world!");
}).await?;
Ok(())
}
Contributing
- Fork it
- Download your fork to your PC
- Create your feature branch (
git checkout -b my-new-feature
) - Make changes and add them (
git add .
) - Commit your changes (
git commit -m 'Add some feature'
) - Push to the branch (
git push origin my-new-feature
) - Create new pull request
Security Vulnerabilities
If you discover a security vulnerability, please send an e-mail to pefish@qq.com. All security vulnerabilities will be promptly addressed.
License
This project is licensed under the Apache License.
Dependencies
~4–15MB
~137K SLoC