Skip to content

cryptidtech/best-practices

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Best Practices

This repo contains a crate called best-practices that contains some really handy bits of code. It demonstrates how to use thiserror and anyhow to easily have one set of Error types for any crate or app. It also demonstrates some handy wrappers for handing Option<PathBuf> structopt options for input and output to easily support both file and stdin/stdout I/O. This makes it easy to construct command line apps that support pipelining (e.g. echo "foo" | grep "foo" -). There's also a number of handy types for scanning directory trees, digesting files and creating indexes of filesystem trees.

Examples

This repo also contains some examples that demonstrate how to construct command line apps the cleanest and easiest way.

About

Rust repo full of useful tricks

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages