Commit debfec2e authored by Jekyll Wu's avatar Jekyll Wu
Browse files

Add environment variable $KONSOLE_PROFILE_NAME

It records the name of the profile used in current tab/session.

FEATURE: 227296
FIXED-IN:4.9
parent f1c4879f
...@@ -466,6 +466,7 @@ void SessionManager::applyProfile(Session* session, const Profile::Ptr profile , ...@@ -466,6 +466,7 @@ void SessionManager::applyProfile(Session* session, const Profile::Ptr profile ,
// (if specified) // (if specified)
QStringList environment = profile->property<QStringList>(Profile::Environment); QStringList environment = profile->property<QStringList>(Profile::Environment);
environment << QString("PROFILEHOME=%1").arg(profile->defaultWorkingDirectory()); environment << QString("PROFILEHOME=%1").arg(profile->defaultWorkingDirectory());
environment << QString("KONSOLE_PROFILE_NAME=%1").arg(profile->name());
session->setEnvironment(environment); session->setEnvironment(environment);
} }
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment