Skip to content

Commit

Permalink
Disable 'Open Git Repository in Terminal' if terminals are not availa…
Browse files Browse the repository at this point in the history
…ble (#930)

* Disable 'Open Git Repository in Terminal' if terminals are not available

https://github.com/jupyterlab/jupyterlab/blob/f0790b3ffd187b7dc923156b8ae227855abecefb/packages/terminal-extension/src/index.ts#L98

* Code formatting
  • Loading branch information
faucct authored Apr 27, 2021
1 parent f0b492a commit ce8fff6
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/commandsAndMenu.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,9 @@ export function addCommands(
main.dispose();
}
},
isEnabled: () => gitModel.pathRepository !== null
isEnabled: () =>
gitModel.pathRepository !== null &&
app.serviceManager.terminals.isAvailable()
});

/** Add open/go to git interface command */
Expand Down

0 comments on commit ce8fff6

Please sign in to comment.