code-d
code-d copied to clipboard
Fix sandboxed environments like flatpak
Sandboxed environments often have a chroot set, creating weird bugs where the users are sure they have D installed, but it can't access dmd nor the import directories. An example for this is the Mint Software store which installs vscode from Flathub.
code-d should detect if it's sandboxed and is missing core components like stdlibs and then take appropriate actions.
if env variable FLATPAK_SANDBOX_DIR is set + missing stdlibs -> download sources from github and tell user that the installation is sandboxed on installation.
I don't think missing executables of dmd and dub can be fixed here except for maybe downloading precompiled ldc binaries on linux?
snap is now officially supported for vscode, should probably look at this asap
I don't think missing executables of dmd and dub can be fixed here
The respective error messages should probably get improved and tell the user what to do.
except for maybe downloading precompiled ldc binaries on linux?
I don't think that this would be a good idea. From my point of view that's the last thing I would want code-d to do.