Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 904981 - sys-apps/less should obey the XDG directory specification
Summary: sys-apps/less should obey the XDG directory specification
Status: RESOLVED UPSTREAM
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo's Team for Core System packages
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-04-24 20:34 UTC by Jeff Gazso
Modified: 2023-04-24 21:47 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Jeff Gazso 2023-04-24 20:34:11 UTC
It looks like sys-apps/less puts lesshst and looks for lesskey in the root of the current user's home directory. Appending something the following to /etc/env.d/70less at install time could address this easily enough:

LESSHISTFILE=$XDG_CACHE_HOME/lesshst
LESSKEY=$XDG_CONFIG_HOME/less/lesskey
Comment 1 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2023-04-24 20:38:37 UTC
Is this backwards compatible?

i.e. If we start setting this, is it going to break for users who have it in their homedir? I suspect it will?
Comment 2 Jeff Gazso 2023-04-24 21:03:44 UTC
Hmm... you might be right. I consider less' history to be disposable but suddenly moving the lesskey (custom key bindings file) might tick some people off. Let me test this a bit.