mirror of
https://github.com/barry-ran/QtScrcpy.git
synced 2025-08-03 06:08:39 +00:00
make config usable in production env
use QTSCRCPY_DEV_ENV flag to preset env vars only in dev env
This commit is contained in:
parent
d45c9b03f4
commit
623feabe13
1 changed files with 2 additions and 0 deletions
|
@ -23,6 +23,7 @@ QtMsgType covertLogLevel(const QString &logLevel);
|
||||||
int main(int argc, char *argv[])
|
int main(int argc, char *argv[])
|
||||||
{
|
{
|
||||||
// set env
|
// set env
|
||||||
|
#ifdef QTSCRCPY_DEV_ENV
|
||||||
#ifdef Q_OS_WIN32
|
#ifdef Q_OS_WIN32
|
||||||
qputenv("QTSCRCPY_ADB_PATH", "../../../../third_party/adb/win/adb.exe");
|
qputenv("QTSCRCPY_ADB_PATH", "../../../../third_party/adb/win/adb.exe");
|
||||||
qputenv("QTSCRCPY_SERVER_PATH", "../../../../third_party/scrcpy-server");
|
qputenv("QTSCRCPY_SERVER_PATH", "../../../../third_party/scrcpy-server");
|
||||||
|
@ -39,6 +40,7 @@ int main(int argc, char *argv[])
|
||||||
qputenv("QTSCRCPY_SERVER_PATH", "../../../third_party/scrcpy-server");
|
qputenv("QTSCRCPY_SERVER_PATH", "../../../third_party/scrcpy-server");
|
||||||
qputenv("QTSCRCPY_CONFIG_PATH", "../../../config");
|
qputenv("QTSCRCPY_CONFIG_PATH", "../../../config");
|
||||||
qputenv("QTSCRCPY_KEYMAP_PATH", "../../../keymap");
|
qputenv("QTSCRCPY_KEYMAP_PATH", "../../../keymap");
|
||||||
|
#endif
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
g_msgType = covertLogLevel(Config::getInstance().getLogLevel());
|
g_msgType = covertLogLevel(Config::getInstance().getLogLevel());
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue