adding devtools tasks to command palette#880
adding devtools tasks to command palette#880ElianHugh merged 4 commits intoREditorSupport:masterfrom
Conversation
|
I wonder if it would be worth moving away from the runTextInTerm paradigm for these commands (I.e. commands that don't influence/affect the R environment). Is there a benefit to running in the terminal as opposed to a task? We have the devtools::check task definition but iirc no command palette bbinding |
|
I think it should be a task instead of sending code to terminal. |
|
I believe that's how RStudio treats it as well, for whatever that's worth. I totally agree that pattern makes more sense. Should that be in the scope of this PR though? |
|
I think for this PR, it would probably be worth pointing the command palette to the task binding. We can do the same for the other command palette bindings in a future PR |
|
Understood. Just to be transparent, that's likely beyond my skill level |
|
No worries, you're 90% there already! I think you would only need to change the command and its arguments. E.g., in my keybindings I have the following: |
6c8f3a1 to
7cffeaf
Compare
|
okay, I think this is the solution you alluded to, @ElianHugh, I appreciate the pointer. I did a bit of research and there's definitely more complex (and I think appropriate) ways to accomplish this. see: microsoft/vscode#40758. any how. I took a couple of liberties in terms of naming and organization. I wanted to be sure the commands that match I then categorized these "Package" command contributions separately in the because, as I was testing, it made the command in the palette clearer. Feel free to revert/change whatever! |
|
Thank you for the nice work you've done! The commands work nicely (barring the one issue I've noted above), and I think the naming is appropriate too. I don't have a strong opinion re: naming the commands r.commandTask, but it may cause unexpected issues for VSCode-R users that have shortcuts pointing to the old command names (e.g. r.test vs r.testTask) |
|
Anything else to add? @renkun-ken |
|
LGTM sorry for late reply! |
What problem did you solve?
while the majority of
devtools::*package develop/build shortcuts were available,devtools::check()was missing.(If you have)Screenshot
(If you do not have screenshot) How can I check this pull request?
Build version >
Cmd + Shift + P> TypeR: Check> Press Enter