Rust
I made this library so that I can use it in all of my rust projects without writing the same codes over and over again
The main Module of this library is Message
which holds 3 functions to return colored Strings & 3 functions to output formatted static String notification messages
-
It has 3 functions which return colored Strings as output
- error (takes 1 argument & returns a red colored String with cross mark)
- success (takes 1 argument & returns a green colored String with tick mark)
- info (takes 1 argument & returns a blue colored String with book info mark)
-
It has 3 functions which outputs formatted static String notifications
- action_failure (takes 1 argument as 'action name' & outputs an action failure message)
- action_complete (takes 1 argument as 'action name' & outputs an action complete message)
- action_notify (takes 2 arguments as 'action name', 'notification info' & outputs an action info message)
-
The String returned by each function, doesn't contain new line character i.e. '\n'
- Rust
- 💀 Minimum Rust Version:
1.78.0
cargo add best_skn_message
use best_skn_message::message;
let error: String = message::error("Error occured!"); panic!("{} \n", error); let success: String = message::success("Process completed!"); println!("{}", success); let info: String = message::info("Process is safe to pause!"); println!("{}", info); let failure: String = message::action_failure("Copy Files"); // Action name as argument panic!("{} \n", failure); let complete: String = message::action_complete("Read Config File"); // Action name as argument println!("{}", complete); let notify: String = message::action_notify("Run Shell Scripts", "Safe to use without error!"); // Action name & notification info message as arguments println!("{}", notify);
- 👩🎨
Prodipta Das Logno
& 🧛♀️Atoshi Sarker Prithula
: The two most special ladies of my life. I can't thank them enough for always treasuring me a lot. I am lucky that I met with these two amazing ladies. They have two special places in my heart and no other girl can ever replace them. - 💯
My Father & Mother
: The greatest treasures of my life ever.