How to rename an existing R package on CRAN
Asked Answered
S

0

7

We submitted an R package on CRAN. Now we want to update our package under a new different name, because more new functions are introduced in this update, and the old name of it doesn't well represent the new release. What are we supposed to do under this circumstance?

The related topics and discussions I can find are only:

  1. from CRAN Repository Policy

    If an update will change the package's API and hence affect packages depending on it, it is expected that you will contact the maintainers of affected packages and suggest changes, and give them time to prepare updates before submitting your updated package. Do mention in the submission email which packages are affected and that their maintainers have been informed. In order to derive the reverse dependencies of a package including the addresses of maintainers who have to be notified upon changes, the function reverse_dependencies_with_maintainers is available from the developer website.

  2. and the question from R-devel mailing list: Rename the package published on CRAN

However, there is no any further instructions specifying the exact steps we should do.

The possible way and steps we can think of are:

  1. submit the update under the new name to CRAN ftp server
  2. inform the maintainers of packages that depends on ours of the rename
  3. send an email to [email protected] to explain and ask for withdrawal of the old package

or:

  1. submit the update under the new name through the submission form
  2. inform the maintainers of packages that depends on ours of the rename
  3. still keep the old package on CRAN and leave a note on the page to point to the new package, but without further update anymore

Which one are better? Or what is the correct way to do?

Surfbird answered 26/3, 2014 at 7:40 Comment(6)
Please remember that people may have included your old package in their scripts. When a new R version rolls around, these scripts will break if you discontinue the old package. And it will be hard for everyone to find the renamed package. Remember that there are packages with pretty weird names, e.g., cran.r-project.org/web/packages/e1071/index.htmlHypognathous
Why don't you do what was done with the gregmisc package (read the description at that page). Split your existing and new functions into new separate packages. Keep your existing package as a package that just "depends" on a set of new packages.Capillaceous
It has been done, see track vs trackObjYounker
@AnandaMahto, Thank you. I think the practice of package gregmisc is great, and can be a good compromise if there is no official way to cope with this circumstance.Surfbird
You could go Hadley on it and rename the second package identical to the first but with a 2 after it and stop active development of the prior.Sublunary
Never go Full Hadley. ;-)Marrowfat

© 2022 - 2024 — McMap. All rights reserved.