Git Product home page Git Product logo

Comments (22)

matyama avatar matyama commented on June 27, 2024

helm >= 3 supports XDG out of the box so it should be safe to drop/migrate ~/.helm (check helm version first tho)

from configs.

matyama avatar matyama commented on June 27, 2024

NSS data in ~/.pki should be safe to move to XDG directories, see: https://bugzilla.mozilla.org/show_bug.cgi?id=818686 . Also Chrome does seem to use XDG (after quick check of the contents of XDG_CONFIG_HOME).

Migration commands:

mkdir -p $XDG_CONFIG_HOME/pki/nssdb $XDG_DATA_HOME/pki/nssdb && \
  mv $HOME/.pki/nssdb/pkcs11.txt $XDG_CONFIG_HOME/pki/nssdb && \
  mv $HOME/.pki/nssdb/*.db $XDG_DATA_HOME/pki/nssdb && \
  rm -r $HOME/.pki 

from configs.

matyama avatar matyama commented on June 27, 2024

NSS data in ~/.pki should be safe to move to XDG directories, see: https://bugzilla.mozilla.org/show_bug.cgi?id=818686. Also Chrome does seem to use XDG (after quick check of the contents of XDG_CONFIG_HOME).

After further testing Chrome does seem to re-create ~/.pki and indeed they have an open issue for it: https://bugs.chromium.org/p/chromium/issues/detail?id=1038587.

Adding an item for it to the list.

from configs.

matyama avatar matyama commented on June 27, 2024

~/.pki is also created by vscode - mentioned in https://bugzilla.mozilla.org/show_bug.cgi?id=818686 and verified

Adding an item for it to the list.

from configs.

matyama avatar matyama commented on June 27, 2024

~/.vscode is problematic too (XDG support is still an open issue). It's contents is

.vscode
├── argv.json
└── extensions

At least partial fix could be

export VSCODE_EXTENSIONS="$XDG_DATA_HOME/vscode/extensions"

or setting a global alias or a script for running code with --user-data-dir ~/.config/vscode --extensions-dir ~/.config/vscode/extensions options.

The argv.json file still remains an issue tho.

from configs.

matyama avatar matyama commented on June 27, 2024

base16-shell has

  • hard-coded ~/.vimrc_background in $BASE16_SHELL_HOME/profile_helper.sh
  • hard-coded ~/.base16_theme which it dynamically symlinks for selected theme/script

Best approach would be to open a PR. Alternatively, for now and to test, profile_helper.sh could be modified/replaced in Makefile (as the last step of base16-shell target).

Note: Probably best place to use for these would be either XDG_STATE_HOME or XDG_CONFIG_HOME.

from configs.

matyama avatar matyama commented on June 27, 2024

ipython >= 8.x supports XDG

It's not quite clear which XDG directories one should use (except obvious XDG_CONFIG_HOME). https://wiki.archlinux.org/title/XDG_Base_Directory mentions that despite the fact $HOME is still the default dotfile path, if XDG directories shoudl be supported and the docs/PRs/issues mention that XDG_CACHE_HOME might be used by cython.

So it should be sufficient to just run

mv ~/.ipython $XDG_CONFIG_HOME/ipython

from configs.

matyama avatar matyama commented on June 27, 2024

GHC should support XDG since 9.2.1 according to this commit.

This means that older versions probably will keep using/creating ~/.ghc, unless changes to ghcup will cover this case as well.

As a potential workaround (perhaps just for older GHC versions), one could set a global ghci alias that will force storing history file locally:

alias ghci="ghci -flocal-ghci-history"

Although, this might pollute the $PWD at unexpected locations, such as $HOME - which would defeat the purpose.

from configs.

matyama avatar matyama commented on June 27, 2024

GHC should support XDG since 9.2.1 according to this commit.

This means that older versions probably will keep using/creating ~/.ghc, unless changes to ghcup will cover this case as well.
....
Although, this might pollute the $PWD at unexpected locations, such as $HOME - which would defeat the purpose.

Even with ghcup changes (see a7b800a), ~/.ghc is still created with older compilers.

from configs.

matyama avatar matyama commented on June 27, 2024

yarn is partially supported and according to the XDG list. The issue is still open as there are two remaining problems with current implementation:

  • ~/.yarnrc has a workaround in the form of an alias using --use-yarnrc with XDG_CONFIG_HOME location
  • There seem to be an empty ~/.yarn/bin dir created that shoudl instead go either to $XDG_DATA_HOME/yarn/bin or XDG_BIN_HOME should be used. There does not seem to be a good solution for that at this moment.

Other than that ~/.yarn should go to XDG_DATA_HOME and other yarn dirs similarly to XDG_CACHE_HOME etc.

from configs.

matyama avatar matyama commented on June 27, 2024

~/.redhat dir is most likely due to vscode's user data collection. Since vscode does not currently support XDG by itself, it's quite unlikely that the telemetry would be configurable.

Therefore, the best option to get rid of ~/.redhat is to disable the telemetry in vscode and just remove the directory.

from configs.

matyama avatar matyama commented on June 27, 2024

Since the shell in use is zsh, bash configs are not commited in this repo. So to change the location of the ~/.bash_history file once can manually run the following:

mkdir -p "$XDG_STATE_HOME"/bash
mv ~/.bash_history $XDG_STATE_HOME/bash/history

and add this line to ~/.bashrc:

export HISTFILE="${XDG_STATE_HOME:-$HOME/.local/state}/bash/history"

from configs.

matyama avatar matyama commented on June 27, 2024

~/.selected_editor is generated/used by select-editor and should not be necessary when EDITOR and VISUAL environment variables are set. For reference see: https://askubuntu.com/questions/55022/changing-default-crontab-editor

Tested by removing the file and running crontab -e and it seems fine - the file was not re-created and it opened in $EDITOR.

from configs.

matyama avatar matyama commented on June 27, 2024

Scala 3 (dotty), does not recognize scala -Dscala.shell.histfile=... and creates ~/.dotty_history when running a REPL.

After some googling, I've not found any relevant resources on this issue - i.e. how to change the default location where the REPL history is stored.

from configs.

matyama avatar matyama commented on June 27, 2024

nvidia-settings does not support XDG specs at this moment. Current workaround is to call it with --config option to set a custom config file path (under XDG_CONFIG_DIR).

c7edcf0 introduces an alias for nvidia-settings which works when called manually from a terminal but ~/.nvidia-settings-rc still gets (re)created when the program is invoked as a Gnome app (i.e. from the menu).

A possible hack to solve the remaining issue could be to modify /usr/share/applications/nvidia-settings.desktop by adding the same --config option to the command underExec. This would also need a sudo update-desktop-database.

from configs.

matyama avatar matyama commented on June 27, 2024

1e95ce3 fixes remaining issue with the Gnome desktop nvidia-settings application config path. There is a

make nvidia-settings-rc-xdg-path

command to edit the desktop entry accordingly.

from configs.

matyama avatar matyama commented on June 27, 2024

4f7f79b removes the auxiliary ~/.zshenv in favor of a (systemd) user-specific config under $XDG_CONFIG_HOME/environment.d/.

from configs.

matyama avatar matyama commented on June 27, 2024

1f2a9a8 is an attempt to get rid of ~/.rpmdb created on Ubuntu (probably by apt or snap or something).

Note that it still might get created, because the overshadowing rpm alias will only work (be set) in ZSH context.

from configs.

matyama avatar matyama commented on June 27, 2024

9872551 moves (and solves the issue of) the ~/.binenv.

from configs.

matyama avatar matyama commented on June 27, 2024

b3c819b splits and moves ~/.kube to $XDG_CONFIG_HOME/kube and $XDG_CACHE_HOME/kube

from configs.

matyama avatar matyama commented on June 27, 2024

8d2bd51 is an attempt to get rid of ~/.debug

Note that the perf config is currently set just for --system, so it's a question, whether if invoked under current USER it's gonna work. The issue with using --user option is that it creates ~/.perfconfig, which defeats the purpose here.

from configs.

matyama avatar matyama commented on June 27, 2024

fe59105 removes thunderbird which solves the issue with ~/.thunderbird

from configs.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.