mirror of
https://github.com/Swordfish90/cool-retro-term.git
synced 2025-11-01 15:42:12 +00:00
Adding command line parameters to reset the default settings and to change the initial profile.
This commit is contained in:
10
app/main.cpp
10
app/main.cpp
@@ -13,7 +13,15 @@ int main(int argc, char *argv[])
|
||||
QApplication app(argc, argv);
|
||||
QQmlApplicationEngine engine;
|
||||
|
||||
// Managing some env variables
|
||||
// Manage command line arguments from the cpp side
|
||||
QStringList args = app.arguments();
|
||||
if (args.contains("-h") || args.contains("--help")) {
|
||||
qDebug() << "Usage: " + args.at(0) + " [--default-settings] [-h|--help]";
|
||||
qDebug() << " --default-settings Run cool-old-term with the default settings";
|
||||
qDebug() << " -p|--profile Run cool-old-term with the given profile.";
|
||||
qDebug() << " -h|--help Print this help.";
|
||||
return 0;
|
||||
}
|
||||
|
||||
// Manage import paths
|
||||
QStringList importPathList = engine.importPathList();
|
||||
|
||||
Reference in New Issue
Block a user