Skip to content

Commit

Permalink
Extract crate name and version from Cargo.toml
Browse files Browse the repository at this point in the history
  • Loading branch information
zenoxygen committed Dec 30, 2023
1 parent c707b38 commit 7ca8757
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/args.rs
Original file line number Diff line number Diff line change
Expand Up @@ -18,12 +18,12 @@
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
// SOFTWARE.

use clap::{App, Arg};
use clap::{crate_name, crate_version, App, Arg};

/// Parse arguments.
pub fn parse_args<'a>() -> clap::ArgMatches<'a> {
App::new("xerus")
.version("0.1.0")
App::new(crate_name!())
.version(crate_version!())
.about("A command-line BitTorrent client, written in Rust.")
.author("zenoxygen <[email protected]>")
.arg(
Expand Down

0 comments on commit 7ca8757

Please sign in to comment.