Closed Freso closed 5 years ago
The official EnhancedDiscord installer allows you to install it to any directory you'd like, and LinuxED was originally modeled after it. After some consideration, as the official EnhancedDiscord installer is made entirely for Windows, I will be defaulting to $XDG_DATA_HOME with optional support for the current directory relative to where the user is. As of now I am very busy with things so this may not happen as fast as I'd like it to.
In commits f11970242ca60127b283a6dc53c27a2909a7183d and 8c10740d8070aff024b76964f92eed822ef41baa, I changed the way the updater works and how the installer handles directories relative to where the user is. I believe this to be a fine alternative to using $XDG_DATA_HOME
or $XDG_CACHE_HOME
as this allows users to have more fine control over where their EnhancedDiscord installation will go. You can now install LinuxED system-wide and not have to worry about updates or installation breaking.
Therefore, I do not believe XDG_CACHE_HOME
is needed and this issue will be closed.
freso@koume ~/D/A/linuxed (master)> LinuxED.py
Welcome to the LinuxED installation script.
Operating on client: STABLE 0.0.9
Please type the number for your desired option:
3
It seems EnhancedDiscord is not installed in the current directory so it was unable to be updated. Please type the number for your desired option:
1
Uninstalling EnhancedDiscord... Successfully uninstalled EnhancedDiscord! Downloading ED... Creating index.js.backup... Patching index.js... Creating config.json... EnhancedDiscord installation complete!
Please type the number for your desired option:
6
Exiting... freso@koume ~/D/A/linuxed (master)> cd ../.. freso@koume ~/Development> LinuxED.py Welcome to the LinuxED installation script.
Operating on client: STABLE 0.0.9
Please type the number for your desired option:
3
It seems EnhancedDiscord is not installed in the current directory so it was unable to be updated. Please type the number for your desired option:
From the XDG Base Directory Specification:
Currently "EnhancedDiscord" is extracted to the directory the script is in, which can clutter the file system and in case
LinuxED.py
is installed system‐wide, it may not be allowed at all (e.g., "FileNotFoundError: [Errno 2] No such file or directory: '/usr/bin/EnhancedDiscord/config.json'
"). The "XDG Base Directory Specification" was made to address these issues.Depending on whether the resulting "EnhancedDiscord" directory is either a data directory that needs to be revisited continuously (e.g., this is where the ED extension "lives") or if it’s treated more like a cache (it’s downloaded and then gets installed into Discord’s own directory/‐ies) the "EnhancedDiscord" directory should be placed under
$XDG_DATA_HOME
(first case) or$XDG_CACHE_HOME
(second case).