|
|
@ -653,7 +653,7 @@ bool SetStartOnSystemStartup(bool fAutoStart) |
|
|
|
#elif defined(Q_OS_LINUX) |
|
|
|
#elif defined(Q_OS_LINUX) |
|
|
|
|
|
|
|
|
|
|
|
// Follow the Desktop Application Autostart Spec:
|
|
|
|
// Follow the Desktop Application Autostart Spec:
|
|
|
|
// http://standards.freedesktop.org/autostart-spec/autostart-spec-latest.html
|
|
|
|
// http://standards.freedesktop.org/autostart-spec/autostart-spec-latest.html
|
|
|
|
|
|
|
|
|
|
|
|
boost::filesystem::path static GetAutostartDir() |
|
|
|
boost::filesystem::path static GetAutostartDir() |
|
|
|
{ |
|
|
|
{ |
|
|
@ -709,8 +709,13 @@ bool SetStartOnSystemStartup(bool fAutoStart) |
|
|
|
// Write a bitcoin.desktop file to the autostart directory:
|
|
|
|
// Write a bitcoin.desktop file to the autostart directory:
|
|
|
|
optionFile << "[Desktop Entry]\n"; |
|
|
|
optionFile << "[Desktop Entry]\n"; |
|
|
|
optionFile << "Type=Application\n"; |
|
|
|
optionFile << "Type=Application\n"; |
|
|
|
optionFile << "Name=Bitcoin\n"; |
|
|
|
if (GetBoolArg("-testnet", false)) |
|
|
|
optionFile << "Exec=" << pszExePath << " -min\n"; |
|
|
|
optionFile << "Name=Bitcoin (testnet)\n"; |
|
|
|
|
|
|
|
else if (GetBoolArg("-regtest", false)) |
|
|
|
|
|
|
|
optionFile << "Name=Bitcoin (regtest)\n"; |
|
|
|
|
|
|
|
else |
|
|
|
|
|
|
|
optionFile << "Name=Bitcoin\n"; |
|
|
|
|
|
|
|
optionFile << "Exec=" << pszExePath << strprintf(" -min -testnet=%d -regtest=%d\n", GetBoolArg("-testnet", false), GetBoolArg("-regtest", false)); |
|
|
|
optionFile << "Terminal=false\n"; |
|
|
|
optionFile << "Terminal=false\n"; |
|
|
|
optionFile << "Hidden=false\n"; |
|
|
|
optionFile << "Hidden=false\n"; |
|
|
|
optionFile.close(); |
|
|
|
optionFile.close(); |
|
|
|