Skip to content

Commit a5dd049

Browse files
authored
Enable LSP in `.Rprofile (#4569)
Addresses #2887 pretty much exactly how @DavisVaughan outlined ### QA Notes You can bring up your own personal `.Rprofile` via `usethis::edit_r_profile()`. Before this PR, there were no features provided by the LSP such as completions, but with this PR we do see LSP features such as completions. You can try typing `libr` and then using <kbd>Tab</kbd> to see the difference.
1 parent ffbcbce commit a5dd049

File tree

2 files changed

+2
-0
lines changed

2 files changed

+2
-0
lines changed

extensions/positron-r/package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -269,6 +269,7 @@
269269
"extensions": [
270270
".R",
271271
".r",
272+
".Rprofile",
272273
".rprofile"
273274
],
274275
"aliases": [

extensions/positron-r/src/provider.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ export const R_DOCUMENT_SELECTORS = [
2424
{ language: 'r', scheme: 'untitled' },
2525
{ language: 'r', scheme: 'inmemory' }, // Console
2626
{ language: 'r', pattern: '**/*.{r,R}' },
27+
{ language: 'r', pattern: '**/*.{rprofile,Rprofile}' },
2728
{ language: 'r', pattern: '**/*.{qmd,Qmd}' },
2829
{ language: 'r', pattern: '**/*.{rmd,Rmd}' },
2930
];

0 commit comments

Comments
 (0)