(fileUri: vscode.Uri)
| 26 | // open the diff editor of a file, such as click it in source-control-panel, |
| 27 | // only work when we can found the corresponding file in source-control-panel |
| 28 | const commandDiffChangedFile = async (fileUri: vscode.Uri) => { |
| 29 | const changedFile = await getChangedFileFromSourceControl(fileUri); |
| 30 | |
| 31 | if (!changedFile) { |
| 32 | return; |
| 33 | } |
| 34 | |
| 35 | const command = await getChangedFileDiffCommand(changedFile); |
| 36 | vscode.commands.executeCommand(command.command, ...(command.arguments || [])); |
| 37 | }; |
| 38 | |
| 39 | const openFileToEditor = async (fileUri) => { |
| 40 | const isCurrentAuthority = fileUri.authority === (await router.getAuthority()); |
nothing calls this directly
no test coverage detected