简体   繁体   English

在版本控制下重命名RStudio项目

[英]Renaming RStudio project under version control

What's the right way to rename an RStudio project (esp., when that project is under version control)? 什么是重命名RStudio项目的正确方法(特别是,当该项目受版本控制时)?

Eg, I created an RStudio project with version control in "~/myproject". 例如,我在“〜/ myproject”中创建了一个带版本控制的RStudio项目。 Then I decided I wanted to rename the project to "myproject1". 然后我决定将项目重命名为“myproject1”。 So I 所以我

  1. renamed "~/myproject" as "~/myproject1" 将“〜/ myproject”重命名为“〜/ myproject1”
  2. renamed "myproject.Rproj" as "myproject1.Rproj" 将“myproject.Rproj”重命名为“myproject1.Rproj”
  3. committed the "rename" changes with git via RStudio. 通过RStudio使用git进行“重命名”更改。

Everything seems to be fine. 一切似乎都很好。 But I have a suspicion I'm missing something and that I'm going to be surprised by some project behavior down the line. 但我怀疑自己错过了什么,而且我会对一些项目行为感到惊讶。

如果您的项目也是R包,则需要编辑DESCRIPTION文件并更改“Package”属性的值以反映新名称。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM