Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 811945

Summary: app-misc/detox-1.4.2: /etc/detoxrc missing
Product: Gentoo Linux Reporter: Oliver Koch <oliver>
Component: Current packagesAssignee: Gentoo Shell Tools project <shell-tools>
Status: RESOLVED FIXED    
Severity: enhancement CC: sam
Priority: Normal    
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---

Description Oliver Koch 2021-09-07 07:51:54 UTC
I think it is safe to assume that most computers, that have detox installed, use UTF-8 as default. 
Without /etc/detoxrc detox will use the iso8859_1 sequence and the user has no other choice, since no other sequences are defined. So the user has to manually copy /usr/share/doc/detox-1.4.2/detoxrc.sample.bz2 to their home, unpack it and rename it to .detoxrc before they can actually use detox.
For that reason I think the detox ebuild should provide a useful /etc/detoxrc.

Reproducible: Always

Steps to Reproduce:
1. touch "Übung.txt"
2. detox .
3. ls lists Aoebung.txt instead of UEbung.txt



42,43d41
<       insinto /etc
<       newins etc/${PN}rc.sample ${PN}rc
Comment 1 Matthew Smith gentoo-dev 2021-09-07 08:55:50 UTC
Maybe it could print a message after installation telling users they should probably copy the config from /usr/share/doc/detox-1.4.2/detoxrc.sample.bz2.
Comment 2 Oliver Koch 2021-09-07 14:22:15 UTC
I ran some tests for different languages with and without .UTF-8 in $LANG. For each combination detox did what I expected when the sample detoxrc was in /etc/.

Following the principle of least surprise I think /etc/detoxrc should exist. Other packages do also provide a system wide default config, is there a reason this package should not?
Comment 3 Larry the Git Cow gentoo-dev 2021-10-14 09:40:51 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=4ee346b3979f6e562f3e6b2bf94858867f81c144

commit 4ee346b3979f6e562f3e6b2bf94858867f81c144
Author:     Sam James <sam@gentoo.org>
AuthorDate: 2021-10-14 09:38:47 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2021-10-14 09:40:42 +0000

    app-misc/detox: install detoxrc
    
    Closes: https://bugs.gentoo.org/811945
    Signed-off-by: Sam James <sam@gentoo.org>

 app-misc/detox/{detox-1.4.2.ebuild => detox-1.4.2-r1.ebuild} | 4 +++-
 app-misc/detox/{detox-1.4.5.ebuild => detox-1.4.5-r1.ebuild} | 4 +++-
 2 files changed, 6 insertions(+), 2 deletions(-)