Buttons to stage and discard selections in Rstudio editor not working

风格不统一 提交于 2020-05-12 19:58:49

问题


I have a problem that I am unable to use the "Stage line/selection" and "Discard line/selection" buttons that appear when selecting specific lines in the Rstudio git review changes. When pressed, the selection disappears and nothing happens.

To illustrate, say I have a file in which I have made some additions and deletions:



Note, the "Stage chunk" and "Discard chunk" buttons on the right works as expected.

Now, say I wish to stage and commit only the added lines (the code comment). I first select the lines:



However, selecting either of the buttons, the first line of the selection is kept and nothing is staged:



Again, nothing happens if "stage chunk" or "discard chunk" is pressed for the single line selection that remains.

The problem seems to be a bit intermittent. My experience is, that it often happens if I have made many and "complex" changes. Editing a few lines does not cause the problem. From searching, I've only found suggestions to avoid spaces in files (which I do not have).

Edit, May 2020 Now appears as an issue at GitHub:

https://github.com/rstudio/rstudio/issues/5476

来源:https://stackoverflow.com/questions/53196915/buttons-to-stage-and-discard-selections-in-rstudio-editor-not-working

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!