Skip to content

Latest commit

 

History

History
44 lines (38 loc) · 940 Bytes

README.md

File metadata and controls

44 lines (38 loc) · 940 Bytes

cargo-edit

cargo install cargo-edit

function_name

#[macro_use] extern crate function_name;
macro_rules! function_path {() => (concat!(module_path!(), "::", function_name!()))}

...

#[named]
pub fn f() {
    println!("\n{}:", function_path!());

TOC

  1. algorithms

     cargo add rand rand_distr
    random::gen_numeric();
    random::gen_numeric_range();
    random::gen_numeric_distribution().unwrap();
    random::gen_random_values_of_t();
    random::gen_alphanumeric_distribution(10);
    random::gen_alphanumeric_from_charset();
    
    vector_sort();
  2. command line cookbook sample broken - refer to https://docs.rs/clap/latest/clap/

    cargo add clap --features derive
    cargo add ansi_term
    cargo run -- --name xxx --count 5  
    parse_args();
    coloured_and_styled();