Skip to main content

Posts

Showing posts from December 22, 2018

Git Delete Command

Git Delete In this post, we will learn delete operation on git using command line on Ubuntu. Delete local branch Delete a git local branch named my_branch  git branch -d my_branch Please write comments if you find anything incorrect, or you want to share more information about the topic discussed above

Rust error: a bin target must be available for `cargo run`

Rust error: a bin target must be available for `cargo run` In this post, we will learn how to fix the rust build error  a bin target must be available for `cargo run`.  In my case I was getting this error because while creating rust project with command  cargo new project_name, the source (src) directory was not containing main.rs but it was containing lib.rs because   cargo new project_name command was creating library not binary project . You can solve above issue by creating project with below command. cargo new project_name --bin Above command will create your project with directory structure /project_name - Cargo.toml - src/main.rs Now you can build and run project with cargo build cargo run Please write comments if you find anything incorrect, or you want to share more information about the topic discussed above