Flatpak: store settings, database and lock file in XDG directories

Open
#275 0 comments 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
52/100
Issue type
Feature
Clarity
Mostly clear
Activity status
Active
Tech stack
java
Domain
backend

Research direction

Start by locating App.APP_CACHE_DIR and the code that creates or uses jdm.properties, the Derby database, and jdm.lock; check how logging reads XDG_STATE_HOME for the approach used in Flatpak. Decide how to handle existing ~/.jdm data, then verify settings, database, and lock files use the intended XDG config and data directories when FLATPAK_ID is set. The issue does not name tests or specify migration behavior.

Written by the indexing model from the issue text.

Description

enhancement linux

Follow-up from #245.

App.APP_CACHE_DIR is ${user.home}/.jdm/<version> and holds jdm.properties, the Derby database and jdm.lock. In a Flatpak this writes into the real home (needs --filesystem=home) and is not removed on uninstall. Flatpak sets XDG_CONFIG_HOME/XDG_DATA_HOME to ~/.var/app/net.jdiskmark.JDiskMark/{config,data}.

  • Use XDG config/data dirs when running in a Flatpak (FLATPAK_ID set), and consider the same on native Linux.
  • Decide on migration of existing ~/.jdm data.
  • Related: logging already uses XDG_STATE_HOME in the Flatpak (#245); see also #264.
Dominant language
Java
Stars
6
Forks
6
Avg merge
10h 11m
Merged PRs (30d)
12

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from JDiskMark/jdm-java

All issues in JDiskMark/jdm-java

Similar issues

More Java issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.