Bug 283102 - konsolerc: usage of full path for some config values is not portable between accounts
Summary: konsolerc: usage of full path for some config values is not portable between ...
Status: RESOLVED FIXED
Alias: None
Product: konsole
Classification: Applications
Component: general (show other bugs)
Version: 2.7.999
Platform: unspecified Linux
: NOR normal
Target Milestone: ---
Assignee: Konsole Developer
URL:
Keywords:
: 209974 (view as bug list)
Depends on:
Blocks:
 
Reported: 2011-09-30 15:27 UTC by Achim Bohnet
Modified: 2012-04-20 05:43 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In: 4.9.0
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Achim Bohnet 2011-09-30 15:27:49 UTC
Version:           2.7.999 (using Devel) 
OS:                Linux

konsolerc uses in 'Favorites Profiles' and 'Profile Shortcuts' the full path.  So one can't copy then from one user to another.   AFAIR there a special config method that that strips at least $HOME from path.  Best IMHO would be to just use the Filename itself without path part (like 'Default Profile' does).

E.g. part of my konsolerc:
[Desktop Entry]
DefaultProfile=Shell.profile

[Favorite Profiles]
Favorites=/home/allee-o/.project-neon-kde/share/apps/konsole/Shell.profile,/home/allee-o/.project-neon-kde/share/apps/konsole/root shell.profile,/opt/project-neon/share/apps/konsole/Shell.profile,/home/allee-o/.project-neon-kde/share/apps/konsole/root @ where-ever.profile

[Profile Shortcuts]
Ctrl+Shift+F10=/home/allee-o/.project-neon-kde/share/apps/konsole/root shell.profile


Reproducible: Always

Steps to Reproduce:
rsync your account to your other user account (local or remote) with a different username.  Start konsole.


Actual Results:  
Profiles are no longer found

Expected Results:  
Favorite Profiles and Short cuts should be available as on the original account

OS: Linux (x86_64) release 3.0.0-12-generic
Compiler: gcc
Comment 1 Jekyll Wu 2011-09-30 16:40:51 UTC
It seems the same issue has been report in bug #209974 by the reporter. It is a bit sad that issue still remains 2 year later.
Comment 2 Jekyll Wu 2011-10-03 06:53:30 UTC
*** Bug 209974 has been marked as a duplicate of this bug. ***
Comment 3 Kurt Hindenburg 2012-01-21 21:33:47 UTC
Git commit 8240973baf59036030dc60aa93bad9489f05bccb by Kurt Hindenburg.
Committed on 21/01/2012 at 22:28.
Pushed by hindenburg into branch 'master'.

Use relative paths in config file

konsolerc uses in 'Favorites Profiles' and 'Profile Shortcuts' the full
path.  Changing this to relative path (if in a KDE location) allows
one user can copy then to another.

FIXED-IN: 4.9
REVIEW: 102749

M  +23   -4    src/SessionManager.cpp

http://commits.kde.org/konsole/8240973baf59036030dc60aa93bad9489f05bccb
Comment 4 Kurt Hindenburg 2012-01-21 21:38:12 UTC
Forgot to put thanks to Francesco Cecconi for patch in the commit... Any reason not to put this in 4.8.1?
Comment 5 Francesco Cecconi 2012-01-22 11:04:08 UTC
The backport is welcome.
Comment 6 Kurt Hindenburg 2012-02-02 15:51:11 UTC
Git commit 053d1f27cda75cd0338d4768d509bff4766366a3 by Kurt Hindenburg.
Committed on 02/02/2012 at 16:50.
Pushed by hindenburg into branch 'KDE/4.8'.

Use relative paths in config file

    konsolerc uses in 'Favorites Profiles' and 'Profile Shortcuts' the full
    path.  Changing this to relative path (if in a KDE location) allows
    one user can copy then to another.

M  +23   -3    src/SessionManager.cpp

http://commits.kde.org/konsole/053d1f27cda75cd0338d4768d509bff4766366a3
Comment 7 Kurt Hindenburg 2012-02-11 21:58:49 UTC
I revert this in KDE/4.8 as well as the patch for https://bugs.kde.org/show_bug.cgi?id=292637

There are a few things I found I don't like.
1. using --profile=/an/absolute/path won't work with the patch
  I do have a working patch for this
2. when using --profile= and then editing the profile, it will be saved under the $KDEHOME. using the profile name.

Since this breaks anyone using #1 I don't care for it in 4.8.x just yet.
Comment 8 Kurt Hindenburg 2012-03-31 13:28:08 UTC
Git commit 2663d9c712f5fa9e707b98e4ea41fe50c99585e8 by Kurt Hindenburg.
Committed on 31/03/2012 at 15:25.
Pushed by hindenburg into branch 'master'.

Allow --profile=full path to work again.

After 8240973baf59036030dc60aa93bad9489f05bccb, using full paths in
--profile didn't work.  This fixes that issue.

It will save the full profile path for favorites and shortcuts if the
profile is not under the normal KDE konsole area.

M  +20   -2    src/ProfileManager.cpp

http://commits.kde.org/konsole/2663d9c712f5fa9e707b98e4ea41fe50c99585e8