在 PC 之间传输所有 ReSharper 设置
我想知道是否有办法将 ReSharper 中的所有设置(包括 ReSharper 设置的 StyleCop 和我为 ReSharper 设置的键盘绑定)从一台 PC 复制到另一台 PC?
I was wondering if there is a way to copy ALL my settings from ReSharper (including the StyleCop for ReSharper settings and the keyboard bindings I have set for ReSharper) from one PC to another?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(7)
由于 Resharper 中的导出选项仅适用于代码样式,因此您需要对所有设置更加巧妙。
来自 彼得·里奇的博客...
我有 Resharper 4.1,所以不是“...\v4.0\vs9.0”,它实际上是“...\v4.1\vs9.0”(很明显,我知道,但值得一提)。
我不确定 StyleCop 设置,但这应该适用于大多数其他设置(键盘方案、代码完成设置等...)。
Since the export option within Resharper is only for code styles, you'll need to be a bit craftier for all settings.
From Peter Ritchie's blog...
I have Resharper 4.1 so instead of "...\v4.0\vs9.0" it's actually "...\v4.1\vs9.0" (obvious, I know, but worth mentioning).
I'm not sure about StyleCop settings, but this should work for most other settings (keyboard scheme, code completion settings, etc...).
resharper 有一个 R# 设置管理器 插件,它存储了我认为的所有内容,包括 stylecop 设置
There is a R# settings manager plugin for resharper that stores all of this I think, including stylecop settings
单击“确定”并将文件保存到所需位置
要将设置导入到其他计算机,请重复步骤 1-3,然后选择从文件导入。 您已完成。
享受!
Click on OK and save the file to your desired location
To import the settings to other computer, repeat steps 1-3 and then select Import from File. You are done.
Enjoy!
您可以导出/导入您的 ReSharper 代码样式或将其放在网络上并在多台计算机之间共享。 为此:
从 VS 菜单中选择 ReSharper -> 然后在选项对话框中选择语言/通用/代码样式共享。
不确定这是否正是您正在寻找的。
You can Export/Import your ReSharper Code Style or put it on the network and share between multiple computers. To do so:
From VS Menu select ReSharper -> Options then in Option dialog select Languages/Common/Code Style Sharing.
Not sure if it's exactly what you're looking for.
StyleCop 设置不存储在 resharper 插件中。 它们位于 stylecop 目录和 xml 文件 (Settings.StyleCop) 中。
StyleCop settings are not stored in the resharper plugin. they are in the stylecop directory and in an xml file (Settings.StyleCop).
我有一个正在使用的解决方案!
Skydrive 和 Junction 连接魔法。
我在文件系统中创建一个连接,将设置指向 skydrive 文件夹。
这样我在使用 skydrive 的任何地方都可以使用相同的设置!
在目标电脑上我做相反的事情。
希望这可以帮助。
I have a solution that i am using!
Skydrive and junction link magic.
I create a junction in the filesystem that point the settings to a skydrive folder.
this way i have everywhere i use skydrive the same settings!!!
On the target pc i do the opposite.
Hope this helps.
Steve Dignan 的答案对于 2009 版 Resharper 来说可能是正确的。
在较新版本的 Resharper 中,PC Resharper 全局设置位于:
%userprofile%\Appdata\Roaming\JetBrains\Shared\vAny\GlobalSettingsStorage.DotSettings
。解决方案团队共享设置位于名为
{Solution Name}.sln.DotSettings
的解决方案文件夹中。解决方案的个人设置位于
{Solution Name}.sln.DotSettings.user
中。来源: https://resharper-support.jetbrains.com/hc/en-us/articles/115001216530-Where-to-find-DotSettings-files-linked-with-settings-layers
所以要转移在 2 台 PC 之间进行设置,复制要传输的相应层的设置文件即可。 通常只需复制全局就足够了。
Steve Dignan's answer is probably correct for 2009 version of Resharper.
In newer versions of Resharper global for PC Resharper settings are located in:
%userprofile%\Appdata\Roaming\JetBrains\Shared\vAny\GlobalSettingsStorage.DotSettings
.Solution team-shared settings are in the solution folder called
{Solution Name}.sln.DotSettings
.Solution's personal settings are in
{Solution Name}.sln.DotSettings.user
.Source: https://resharper-support.jetbrains.com/hc/en-us/articles/115001216530-Where-to-find-DotSettings-files-associated-with-settings-layers
So to transfer settings between 2 PCs, copy settings file(s) for the appropriate layer(s) you want to transfer and that's it. Usually just copying global is enough.