wslu icon indicating copy to clipboard operation
wslu copied to clipboard

USE XDG_CACHE instead of ~/.config/wslu

Open woutervh opened this issue 8 months ago • 1 comments

Windows Version

Windows 11

Windows Build Number

latest

WSL Version

WSL 2

Distro Version

Almalinux

WSL Utilities Version

wslu v4.1.1-1

Describe the bug

files are being created in a hardcoded ~/.config/wslu:

  • baseexec
  • oemcp
  • triggered_time

but these are not config-files. rather cache-files or state

To avoid hardcoding: better use: XDG_CONFIG_HOME (default to ~/.config)

or better: XDG_STATE_HOME (default to~/.local/state) XDG_CACHE_HOME (default to~/.cache)

Steps to Reproduce

ls ~/.config/wlu

  • baseexec
  • oemcp
  • triggered_time

Expected behavior

ls ~/.cache/wlu

  • baseexec
  • oemcp
  • triggered_time

Additional context

No response

Code of Conduct

  • [X] I agree to follow this project's Code of Conduct

woutervh avatar Oct 11 '23 09:10 woutervh

Thanks for the report and currently working on it.

patrick330602 avatar Nov 12 '23 10:11 patrick330602