Alternative to a literal "/home/alex" string in Cutereport
Qt based report solution
Brought to you by:
f0x0x1
Hi!
In the common.pri file, instead of a "/home/alex" string, a (maybe) more adequate string may be
$(HOME)
to indicate the home directory, a string valid for everyone.
For example, instead of
REPORT_ROOT_PATH = "/home/alex/temp/install/cutereport/"
# path for variables in home dir
REPORT_VARS_PATH = "temp/cutereport/"
it might be used
REPORT_ROOT_PATH = "$(HOME)/temp/install/cutereport/"
# path for variables in home dir
REPORT_VARS_PATH = "$(HOME)/temp/cutereport/"
Note: The variable $$PRO_FILE_PWD also might be used in some cases (http://qt-project.org/doc/qt-4.8/qmake-variable-reference.html#pro-file-pwd).
Thank you for CuteReport!
Thank you for the good point. Unfortunately, I don't know yet how to detect home dir in a crossplatform way. $(HOME) could work on Linux and MacOS, but not sure about Windows.
I would appreciate any help.