#cargo #package #rename #renamepkg

bin+lib cargo-renamepkg

A simple utility to help you rename a package

4 releases (2 stable)

1.1.0 Sep 25, 2020
1.0.0 Sep 25, 2020
0.1.1 Sep 22, 2020
0.1.0 Sep 22, 2020

#560 in Cargo plugins

Download history 30/week @ 2024-02-26 8/week @ 2024-03-04 10/week @ 2024-03-11 7/week @ 2024-03-18 61/week @ 2024-04-01

79 downloads per month

MIT license

6KB
84 lines

cargo-renamepkg

This is a simple utility to help you rename a cargo package when you may create a package with an unexpected name or just want to change its name.

Use Case

Suppose that you wanted to do this:

cargo new my_project

But actually you did this:

cargo new my_projcet

When facing such an embarrassing situation, just use this utility:

cargo renamepkg my_projcet my_project

And cargo renamepkg does two things for you:

  • renames the directory
  • replaces the package name with new one in Cargo.toml

Usage

cargo renamepkg <TARGET_PATH> <NEW_NAME>

Installation

cargo install cargo-renamepkg

Contribution

Any questions/advices/contributions are welcomed!


lib.rs:

cargo renamepkg

cargo renamepkg is a simple utility to help you rename a cargo package when you may create packages with unexpected names or just want to change its name.

Usage

cargo renamepkg <TARGET_PATH> <NEW_NAME>

Dependencies

~3.5MB
~61K SLoC