File tree Expand file tree Collapse file tree 4 files changed +8
-8
lines changed Expand file tree Collapse file tree 4 files changed +8
-8
lines changed Original file line number Diff line number Diff line change @@ -10,7 +10,7 @@ import { kEditorInfos, scanForEditors } from "./editor.ts";
1010
1111import {
1212 isInteractiveTerminal ,
13- isRStudioWorkbench ,
13+ isPositWorkbench ,
1414} from "../../core/platform.ts" ;
1515import { runningInCI } from "../../core/ci-info.ts" ;
1616
@@ -60,7 +60,7 @@ export const createCommand = new Command()
6060 const allowPrompt = isInteractive && ! ! options . prompt && ! options . json ;
6161
6262 // Specific case where opening automatically in an editor is not allowed
63- if ( options . open !== false && isRStudioWorkbench ( ) ) {
63+ if ( options . open !== false && isPositWorkbench ( ) ) {
6464 if ( options . open !== undefined ) {
6565 info (
6666 `The --open option is not supported in Posit Workbench - ignoring` ,
Original file line number Diff line number Diff line change @@ -76,8 +76,8 @@ import {
7676 safeExistsSync ,
7777} from "../../core/path.ts" ;
7878import {
79+ isPositWorkbench ,
7980 isRStudio ,
80- isRStudioWorkbench ,
8181 isServerSession ,
8282 isVSCodeServer ,
8383 vsCodeServerProxyUri ,
@@ -872,7 +872,7 @@ function pdfFileRequestHandler(
872872 const onRequest = pdfOptions . onRequest ;
873873 pdfOptions . onRequest = async ( req : Request ) => {
874874 if ( new URL ( req . url ) . pathname === "/" ) {
875- const url = isRStudioWorkbench ( )
875+ const url = isPositWorkbench ( )
876876 ? await rswURL ( port , kPdfJsInitialPath )
877877 : isVSCodeServer ( )
878878 ? vsCodeServerProxyUri ( ) ! . replace ( "{{port}}" , `${ port } ` ) +
Original file line number Diff line number Diff line change @@ -34,7 +34,7 @@ export function isVSCodeServer() {
3434 return ! ! vsCodeServerProxyUri ( ) ;
3535}
3636
37- export function isRStudioWorkbench ( ) {
37+ export function isPositWorkbench ( ) {
3838 // RS_SERVER_URL e.g. https://daily-rsw.soleng.rstudioservices.com/
3939 // RS_SESSION_URL e.g. /s/eae053c9ab5a71168ee19/
4040 return ! ! Deno . env . get ( "RS_SERVER_URL" ) && ! ! Deno . env . get ( "RS_SESSION_URL" ) ;
@@ -50,7 +50,7 @@ export function isPositronTerminal() {
5050}
5151
5252export function isServerSession ( ) {
53- return isRStudioServer ( ) || isRStudioWorkbench ( ) || isJupyterServer ( ) ||
53+ return isRStudioServer ( ) || isPositWorkbench ( ) || isJupyterServer ( ) ||
5454 isJupyterHubServer ( ) || isVSCodeServer ( ) ;
5555}
5656
Original file line number Diff line number Diff line change @@ -10,8 +10,8 @@ import * as colors from "fmt/colors";
1010import {
1111 isJupyterHubServer ,
1212 isJupyterServer ,
13+ isPositWorkbench ,
1314 isRStudioServer ,
14- isRStudioWorkbench ,
1515 isVSCodeServer ,
1616 isVSCodeTerminal ,
1717 jupyterHubHttpReferrer ,
@@ -58,7 +58,7 @@ export async function printBrowsePreviewMessage(
5858 path : string ,
5959) {
6060 if (
61- ( isJupyterServer ( ) || isVSCodeTerminal ( ) ) && isRStudioWorkbench ( )
61+ ( isJupyterServer ( ) || isVSCodeTerminal ( ) ) && isPositWorkbench ( )
6262 ) {
6363 const url = await rswURL ( port , path ) ;
6464 info ( `\nPreview server: ${ previewURL ( host , port , path = "" ) } ` ) ;
You can’t perform that action at this time.
0 commit comments