forked from onivim/oni2
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(workspace/onivim#2742): OSX - Crash with Cmd+P on first launch (o…
…nivim#2761) __Issue:__ Onivim may crash on OSX with `Cmd+P` when launching from finder for the first time __Defect:__ The default directory for Onivim was set to the `Documents` folder. However, Onivim may not actually have permission to access this folder due to OSX's sandboxing. __Fix:__ If we don't have permission, don't set a workspace and fall-back to `Cmd+P` opening active buffers. onivim#2711 helped this particular scenario, by setting up state and UI for the case where no workspace is opened / the working directory is not valid. However, there is still the case that we may have persisted the `Documents` folder, and we could still get that or another invalid folder coming from persistence. Therefore, we need to check permission for the folder prior to changing directory. __TODO:__ - [x] Remove getWorkingDirectory in QuickMenuStoreConnector - [x] Test on OSX w/ no persistence set - [x] Test on OSX w/ persistence set to 'documents' folder - [x] Test on Windows w/ no persistence set - [x] Test on Linux w/ no persistence set Fixes onivim#2742
- Loading branch information
Showing
5 changed files
with
122 additions
and
51 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters