Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions build/lib/electron.ts
Original file line number Diff line number Diff line change
Expand Up @@ -172,6 +172,7 @@ export const config = {
'Xcode workspace file': 'xcworkspace',
'Visual Basic script': 'vb',
'R source code': 'r',
'R Data file': ['rdata', 'RData', 'rda'],
'Rust source code': 'rs',
'Restructured Text document': 'rst',
'LaTeX document': ['tex', 'cls'],
Expand Down
24 changes: 24 additions & 0 deletions build/win32/positron.iss
Original file line number Diff line number Diff line change
Expand Up @@ -402,6 +402,30 @@ Root: {#SoftwareClassesRootKey}; Subkey: "Software\Classes\{#RegValueName}.rprof
Root: {#SoftwareClassesRootKey}; Subkey: "Software\Classes\{#RegValueName}.rprofile\shell\open"; ValueType: string; ValueName: "Icon"; ValueData: """{app}\{#ExeBasename}.exe"""; Tasks: associatewithfiles
Root: {#SoftwareClassesRootKey}; Subkey: "Software\Classes\{#RegValueName}.rprofile\shell\open\command"; ValueType: string; ValueName: ""; ValueData: """{app}\{#ExeBasename}.exe"" ""%1"""; Tasks: associatewithfiles

Root: {#SoftwareClassesRootKey}; Subkey: "Software\Classes\.rdata\OpenWithProgids"; ValueType: none; ValueName: "{#RegValueName}"; Flags: deletevalue uninsdeletevalue; Tasks: associatewithfiles
Root: {#SoftwareClassesRootKey}; Subkey: "Software\Classes\.rdata\OpenWithProgids"; ValueType: string; ValueName: "{#RegValueName}.rdata"; ValueData: ""; Flags: uninsdeletevalue; Tasks: associatewithfiles
Root: {#SoftwareClassesRootKey}; Subkey: "Software\Classes\{#RegValueName}.rdata"; ValueType: string; ValueName: ""; ValueData: "{cm:SourceFile,R Data}"; Flags: uninsdeletekey; Tasks: associatewithfiles
Root: {#SoftwareClassesRootKey}; Subkey: "Software\Classes\{#RegValueName}.rdata"; ValueType: string; ValueName: "AppUserModelID"; ValueData: "{#AppUserId}"; Flags: uninsdeletekey; Tasks: associatewithfiles
Root: {#SoftwareClassesRootKey}; Subkey: "Software\Classes\{#RegValueName}.rdata\DefaultIcon"; ValueType: string; ValueName: ""; ValueData: "{app}\resources\app\resources\win32\default.ico"; Tasks: associatewithfiles
Root: {#SoftwareClassesRootKey}; Subkey: "Software\Classes\{#RegValueName}.rdata\shell\open"; ValueType: string; ValueName: "Icon"; ValueData: """{app}\{#ExeBasename}.exe"""; Tasks: associatewithfiles
Root: {#SoftwareClassesRootKey}; Subkey: "Software\Classes\{#RegValueName}.rdata\shell\open\command"; ValueType: string; ValueName: ""; ValueData: """{app}\{#ExeBasename}.exe"" ""%1"""; Tasks: associatewithfiles

Root: {#SoftwareClassesRootKey}; Subkey: "Software\Classes\.RData\OpenWithProgids"; ValueType: none; ValueName: "{#RegValueName}"; Flags: deletevalue uninsdeletevalue; Tasks: associatewithfiles
Root: {#SoftwareClassesRootKey}; Subkey: "Software\Classes\.RData\OpenWithProgids"; ValueType: string; ValueName: "{#RegValueName}.RData"; ValueData: ""; Flags: uninsdeletevalue; Tasks: associatewithfiles
Root: {#SoftwareClassesRootKey}; Subkey: "Software\Classes\{#RegValueName}.RData"; ValueType: string; ValueName: ""; ValueData: "{cm:SourceFile,R Data}"; Flags: uninsdeletekey; Tasks: associatewithfiles
Root: {#SoftwareClassesRootKey}; Subkey: "Software\Classes\{#RegValueName}.RData"; ValueType: string; ValueName: "AppUserModelID"; ValueData: "{#AppUserId}"; Flags: uninsdeletekey; Tasks: associatewithfiles
Root: {#SoftwareClassesRootKey}; Subkey: "Software\Classes\{#RegValueName}.RData\DefaultIcon"; ValueType: string; ValueName: ""; ValueData: "{app}\resources\app\resources\win32\default.ico"; Tasks: associatewithfiles
Root: {#SoftwareClassesRootKey}; Subkey: "Software\Classes\{#RegValueName}.RData\shell\open"; ValueType: string; ValueName: "Icon"; ValueData: """{app}\{#ExeBasename}.exe"""; Tasks: associatewithfiles
Root: {#SoftwareClassesRootKey}; Subkey: "Software\Classes\{#RegValueName}.RData\shell\open\command"; ValueType: string; ValueName: ""; ValueData: """{app}\{#ExeBasename}.exe"" ""%1"""; Tasks: associatewithfiles

Root: {#SoftwareClassesRootKey}; Subkey: "Software\Classes\.rda\OpenWithProgids"; ValueType: none; ValueName: "{#RegValueName}"; Flags: deletevalue uninsdeletevalue; Tasks: associatewithfiles
Root: {#SoftwareClassesRootKey}; Subkey: "Software\Classes\.rda\OpenWithProgids"; ValueType: string; ValueName: "{#RegValueName}.rda"; ValueData: ""; Flags: uninsdeletevalue; Tasks: associatewithfiles
Root: {#SoftwareClassesRootKey}; Subkey: "Software\Classes\{#RegValueName}.rda"; ValueType: string; ValueName: ""; ValueData: "{cm:SourceFile,R Data}"; Flags: uninsdeletekey; Tasks: associatewithfiles
Root: {#SoftwareClassesRootKey}; Subkey: "Software\Classes\{#RegValueName}.rda"; ValueType: string; ValueName: "AppUserModelID"; ValueData: "{#AppUserId}"; Flags: uninsdeletekey; Tasks: associatewithfiles
Root: {#SoftwareClassesRootKey}; Subkey: "Software\Classes\{#RegValueName}.rda\DefaultIcon"; ValueType: string; ValueName: ""; ValueData: "{app}\resources\app\resources\win32\default.ico"; Tasks: associatewithfiles
Root: {#SoftwareClassesRootKey}; Subkey: "Software\Classes\{#RegValueName}.rda\shell\open"; ValueType: string; ValueName: "Icon"; ValueData: """{app}\{#ExeBasename}.exe"""; Tasks: associatewithfiles
Root: {#SoftwareClassesRootKey}; Subkey: "Software\Classes\{#RegValueName}.rda\shell\open\command"; ValueType: string; ValueName: ""; ValueData: """{app}\{#ExeBasename}.exe"" ""%1"""; Tasks: associatewithfiles

Root: {#SoftwareClassesRootKey}; Subkey: "Software\Classes\.sass\OpenWithProgids"; ValueType: none; ValueName: "{#RegValueName}"; Flags: deletevalue uninsdeletevalue; Tasks: associatewithfiles
Root: {#SoftwareClassesRootKey}; Subkey: "Software\Classes\.sass\OpenWithProgids"; ValueType: string; ValueName: "{#RegValueName}.sass"; ValueData: ""; Flags: uninsdeletevalue; Tasks: associatewithfiles
Root: {#SoftwareClassesRootKey}; Subkey: "Software\Classes\{#RegValueName}.sass"; ValueType: string; ValueName: ""; ValueData: "{cm:SourceFile,Sass}"; Flags: uninsdeletekey; Tasks: associatewithfiles
Expand Down
111 changes: 110 additions & 1 deletion extensions/positron-r/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,9 @@
},
"icon": "icon.png",
"activationEvents": [
"onStartupFinished"
"onStartupFinished",
"onLanguage:rdata",
"onLanguage:rds"
],
"contributes": {
"commands": [
Expand Down Expand Up @@ -145,6 +147,21 @@
"command": "r.interpreters.settingsInfo",
"category": "R",
"title": "%r.command.interpreters.settingsInfo.title%"
},
{
"command": "r.loadRDataFile",
"category": "R",
"title": "%r.command.loadRDataFile.title%"
},
{
"command": "r.loadRdsFile",
"category": "R",
"title": "%r.command.loadRdsFile.title%"
},
{
"command": "r.loadRDataFileWithPicker",
"category": "R",
"title": "%r.command.loadRDataFileWithPicker.title%"
}
],
"configuration": [
Expand Down Expand Up @@ -444,6 +461,38 @@
".Rd"
],
"configuration": "./language-configuration/r-docs-language-configuration.json"
},
{
"id": "rdata",
"aliases": [
"R Data",
"RData"
],
"extensions": [
".RData",
".Rdata",
".rdata",
".rda"
],
"icon": {
"light": "./resources/icons/r-data-light.svg",
"dark": "./resources/icons/r-data-dark.svg"
}
},
{
"id": "rds",
"aliases": [
"R Data Single",
"RDS"
],
"extensions": [
".rds",
".RDS"
],
"icon": {
"light": "./resources/icons/r-data-light.svg",
"dark": "./resources/icons/r-data-dark.svg"
}
}
],
"grammars": [
Expand Down Expand Up @@ -535,6 +584,18 @@
}
],
"menus": {
"explorer/context": [
{
"command": "r.loadRDataFile",
"group": "R",
"when": "resourceExtname == '.RData' || resourceExtname == '.Rdata' || resourceExtname == '.rdata' || resourceExtname == '.rda'"
},
{
"command": "r.loadRdsFile",
"group": "R",
"when": "resourceExtname == '.rds' || resourceExtname == '.RDS'"
}
],
"commandPalette": [
{
"category": "R",
Expand Down Expand Up @@ -611,6 +672,20 @@
"category": "R",
"command": "r.packageCheck",
"when": "isRPackage"
},
{
"category": "R",
"command": "r.loadRDataFile",
"when": "resourceExtname == '.RData' || resourceExtname == '.rdata' || resourceExtname == '.rda'"
},
{
"category": "R",
"command": "r.loadRdsFile",
"when": "resourceExtname == '.rds' || resourceExtname == '.RDS'"
},
{
"category": "R",
"command": "r.loadRDataFileWithPicker"
}
],
"file/newFile": [
Expand Down Expand Up @@ -708,6 +783,40 @@
"supportsUiLaunch": false
}
],
"customEditors": [
{
"viewType": "positron-r.rdataLoader",
"displayName": "%r.customEditor.rdataLoader.displayName%",
"priority": "default",
"selector": [
{
"filenamePattern": "*.RData"
},
{
"filenamePattern": "*.Rdata"
},
{
"filenamePattern": "*.rdata"
},
{
"filenamePattern": "*.rda"
}
]
},
{
"viewType": "positron-r.rdsLoader",
"displayName": "%r.customEditor.rdsLoader.displayName%",
"priority": "default",
"selector": [
{
"filenamePattern": "*.rds"
},
{
"filenamePattern": "*.RDS"
}
]
}
],
"notebookRenderer": [
{
"id": "positron.r.htmlwidget",
Expand Down
8 changes: 6 additions & 2 deletions extensions/positron-r/package.nls.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,11 @@
"r.command.selectInterpreter.title": "Select Interpreter",
"r.command.rmarkdownRender.title": "Render Document With R Markdown",
"r.command.interpreters.settingsInfo.title": "Print interpreter settings information to Output",
"r.command.loadRDataFile.title": "Load R Objects",
"r.command.loadRdsFile.title": "Load R Object",
"r.command.loadRDataFileWithPicker.title": "Load R Data File...",
"r.customEditor.rdataLoader.displayName": "R Workspace Loader",
"r.customEditor.rdsLoader.displayName": "R Object Loader",
"r.menu.createNewFile.title": "R File",
"r.menu.insertPipe.title": "Insert the pipe operator",
"r.menu.insertLeftAssignment.title": "Insert the \"<-\" assignment operator",
Expand Down Expand Up @@ -86,6 +91,5 @@
"r.walkthrough.migrateFromRStudio.workspaces.description": " \n[Open an existing folder](command:workbench.action.files.openFolder)",
"r.walkthrough.migrateFromRStudio.formatting.title": "Formatting your R code",
"r.walkthrough.migrateFromRStudio.formatting.description": " \n[Configure Air to format on save](command:r.walkthrough.formatOnSave)",
"r.welcome.views.debugger.content": "Positron currently provides limited debugging support for R code, but you can use R's native debugging features in Positron.\n[Learn more](https://positron.posit.co/guide-r.html#debugging)"

"r.welcome.views.debugger.content": "Positron currently provides limited debugging support for R code, but you can use R's native debugging features in Positron.\n[Learn more](https://positron.posit.co/guide-r.html#debugging)"
}
45 changes: 45 additions & 0 deletions extensions/positron-r/resources/icons/r-data-dark.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
45 changes: 45 additions & 0 deletions extensions/positron-r/resources/icons/r-data-light.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading