VirtualBox

儲存庫 vbox 的更動 82921


忽略:
時間撮記:
2020-1-30 上午11:00:45 (5 年 以前)
作者:
vboxsync
svn:sync-xref-src-repo-rev:
135902
訊息:
Main/VBoxSVC: Implemented command line help for XPCOM implementation (-hhelp).
檔案:
修改 1 筆資料

圖例:

未更動
新增
刪除
  • trunk/src/VBox/Main/src-server/xpcom/server.cpp

    r76592 r82921  
    3232
    3333#include <VBox/param.h>
     34#include <VBox/version.h>
    3435
    3536#include <iprt/buildconfig.h>
     
    628629}
    629630
     631static void showUsage(const char *pcszFileName)
     632{
     633    RTPrintf(VBOX_PRODUCT " VBoxSVC "
     634             VBOX_VERSION_STRING "\n"
     635             "(C) 2005-" VBOX_C_YEAR " " VBOX_VENDOR "\n"
     636             "All rights reserved.\n"
     637             "\n");
     638    RTPrintf("By default the service will be started in the background.\n"
     639             "\n");
     640    RTPrintf("Usage:\n"
     641             "\n");
     642    RTPrintf("  %s\n", pcszFileName);
     643    RTPrintf("\n");
     644    RTPrintf("Options:\n");
     645    RTPrintf("  -a, --automate            Start XPCOM on demand and daemonize.\n");
     646    RTPrintf("  -A, --auto-shutdown       Shuts down service if no longer in use.\n");
     647    RTPrintf("  -d, --daemonize           Starts service in background.\n");
     648    RTPrintf("  -D, --shutdown-delay <ms> Sets shutdown delay in ms.\n");
     649    RTPrintf("  -h, --help                Displays this help.\n");
     650    RTPrintf("  -p, --pidfile <path>      Uses a specific pidfile.\n");
     651    RTPrintf("  -F, --logfile <path>      Uses a specific logfile.\n");
     652    RTPrintf("  -R, --logrotate <count>   Number of old log files to keep.\n");
     653    RTPrintf("  -S, --logsize <bytes>     Maximum size of a log file before rotating.\n");
     654    RTPrintf("  -I, --loginterval <s>     Maximum amount of time to put in a log file.\n");
     655
     656    RTPrintf("\n");
     657}
     658
    630659int main(int argc, char **argv)
    631660{
     
    643672        { "--auto-shutdown",    'A', RTGETOPT_REQ_NOTHING },
    644673        { "--daemonize",        'd', RTGETOPT_REQ_NOTHING },
     674        { "--help",             'h', RTGETOPT_REQ_NOTHING },
    645675        { "--shutdown-delay",   'D', RTGETOPT_REQ_UINT32 },
    646676        { "--pidfile",          'p', RTGETOPT_REQ_STRING },
     
    709739
    710740            case 'h':
    711                 RTPrintf("no help\n");
     741                showUsage(argv[0]);
    712742                return RTEXITCODE_SYNTAX;
    713743
注意: 瀏覽 TracChangeset 來幫助您使用更動檢視器

© 2025 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette