用于插入 roxygen #' 注释开始的键盘快捷键 [英] Keyboard shortcut for inserting roxygen #' comment start

查看:81
本文介绍了用于插入 roxygen #' 注释开始的键盘快捷键的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

这个问题可能被过度回答了,但我找不到.基本上我使用 RStudio 和键盘快捷键 cmd + shift + c 插入注释.是否有其他组合可以直接插入 roxygen 标签 #' ?或者当我按下 cmd + shift + c 时修改 RStudio 以告诉它添加 ' 的方法?

This question might be over-answered but I could not find one. Basically I am using RStudio and the keyboard shortcut cmd + shift + c for inserting comments. Is there an other combination to insert directly the roxygen tags #' ? Or a way to modify RStudio to tell it to add the ' when I press cmd + shift + c?

推荐答案

您可以使用 RStudio 插件,您将需要一个相当新版本的 RStudio.我刚刚创建了一个 RStudio 插件,它使用 roxygen2 标签注释/取消注释,即就像代码注释一样工作,但使用 #'.该插件托管在 github 上.

You could use an RStudio addin, you'll need a fairly recent version of RStudio. I've just created an RStudio addin that comments/uncomments using roxygen2 tags, i.e. works just like code commenting, but with #'. The addin is hosted on github.

只需安装并附加一个方便的键盘快捷键即可.

Just install and attach a convenient keyboard shortcut.

如果您对其他可用的插件感兴趣,请参阅 addinmanager 插件.

If you are interested in other available addins, see the addinmanager addin.

这篇关于用于插入 roxygen #' 注释开始的键盘快捷键的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆