mirror of
https://github.com/adobe/brackets.git
synced 2024-11-20 01:42:55 +01:00
Merge pull request #15096 from niteskum/WinPathIssueWithExtEditor
Path is converted to windows style when opening with external editor in win
This commit is contained in:
commit
b4abc5ae74
@ -48,9 +48,16 @@ define(function (require, exports, module) {
|
||||
|
||||
var extensionToExtApplicationMap = {};
|
||||
|
||||
function convertUnixPathToWindowsPath(path) {
|
||||
if (brackets.platform === "win" && path && path[1] === ":" && path[2] === "/") {
|
||||
path = path.replace(RegExp('/','g'), '\\');
|
||||
}
|
||||
return path;
|
||||
}
|
||||
|
||||
function _openWithExternalApplication(event, path) {
|
||||
_nodeDomain.exec("open", {
|
||||
path: path,
|
||||
path: convertUnixPathToWindowsPath(path),
|
||||
app: extensionToExtApplicationMap[FileUtils.getFileExtension(path).toLowerCase()]
|
||||
});
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user