Changeset 94208 in vbox for trunk/src/VBox/Frontends
- Timestamp:
- Mar 13, 2022 7:48:18 PM (3 years ago)
- Location:
- trunk/src/VBox/Frontends/VBoxManage
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VBoxManage/VBoxManage.cpp
r94207 r94208 232 232 { "sharedfolder", USAGE_S_NEWCMD, HELP_CMD_SHAREDFOLDER, handleSharedFolder, 0 }, 233 233 #ifdef VBOX_WITH_GUEST_PROPS 234 { "guestproperty", USAGE_ GUESTPROPERTY, VBMG_CMD_TODO, handleGuestProperty, 0 },234 { "guestproperty", USAGE_S_NEWCMD,HELP_CMD_GUESTPROPERTY, handleGuestProperty, 0 }, 235 235 #endif 236 236 #ifdef VBOX_WITH_GUEST_CONTROL -
trunk/src/VBox/Frontends/VBoxManage/VBoxManage.h
r94207 r94208 109 109 USAGE_I_MODUNINSTALL, 110 110 USAGE_I_RENAMEVMDK, 111 #ifdef VBOX_WITH_GUEST_PROPS112 USAGE_GUESTPROPERTY,113 #endif /* VBOX_WITH_GUEST_PROPS defined */114 111 USAGE_I_CONVERTTORAW, 115 112 USAGE_METRICS, … … 255 252 RTEXITCODE handleDebugVM(HandlerArg *a); 256 253 257 /* VBoxManageGuestProp.cpp */258 extern void usageGuestProperty(PRTSTREAM pStrm, const char *pcszSep1, const char *pcszSep2);259 260 254 /* VBoxManageGuestCtrl.cpp */ 261 255 extern void usageGuestControl(PRTSTREAM pStrm, const char *pcszSep1, const char *pcszSep2, uint64_t fSubcommandScope); -
trunk/src/VBox/Frontends/VBoxManage/VBoxManageGuestProp.cpp
r94184 r94208 54 54 55 55 56 void usageGuestProperty(PRTSTREAM pStrm, const char *pcszSep1, const char *pcszSep2)57 {58 RTStrmPrintf(pStrm, "%s guestproperty %s get <uuid|vmname>\n"59 " <property> [--verbose]\n"60 "\n", pcszSep1, pcszSep2);61 RTStrmPrintf(pStrm, "%s guestproperty %s set <uuid|vmname>\n"62 " <property> [<value> [--flags <flags>]]\n"63 "\n", pcszSep1, pcszSep2);64 RTStrmPrintf(pStrm, "%s guestproperty %s delete|unset <uuid|vmname>\n"65 " <property>\n"66 "\n", pcszSep1, pcszSep2);67 RTStrmPrintf(pStrm, "%s guestproperty %s enumerate <uuid|vmname>\n"68 " [--patterns <patterns>]\n"69 "\n", pcszSep1, pcszSep2);70 RTStrmPrintf(pStrm, "%s guestproperty %s wait <uuid|vmname> <patterns>\n"71 " [--timeout <msec>] [--fail-on-timeout]\n"72 "\n", pcszSep1, pcszSep2);73 }74 75 56 #ifndef VBOX_ONLY_DOCS 76 57 … … 78 59 { 79 60 HRESULT rc = S_OK; 61 62 setCurrentSubcommand(HELP_SCOPE_GUESTPROPERTY_GET); 80 63 81 64 bool verbose = false; … … 85 68 verbose = true; 86 69 else if (a->argc != 2) 87 return errorSyntax( USAGE_GUESTPROPERTY,GuestProp::tr("Incorrect parameters"));70 return errorSyntax(GuestProp::tr("Incorrect parameters")); 88 71 89 72 ComPtr<IMachine> machine; … … 121 104 HRESULT rc = S_OK; 122 105 106 setCurrentSubcommand(HELP_SCOPE_GUESTPROPERTY_SET); 107 123 108 /* 124 109 * Check the syntax. We can deduce the correct syntax from the number of … … 144 129 usageOK = false; 145 130 if (!usageOK) 146 return errorSyntax( USAGE_GUESTPROPERTY,GuestProp::tr("Incorrect parameters"));131 return errorSyntax(GuestProp::tr("Incorrect parameters")); 147 132 /* This is always needed. */ 148 133 pszName = a->argv[1]; … … 179 164 HRESULT rc = S_OK; 180 165 166 setCurrentSubcommand(HELP_SCOPE_GUESTPROPERTY_UNSET); 167 181 168 /* 182 169 * Check the syntax. We can deduce the correct syntax from the number of … … 188 175 usageOK = false; 189 176 if (!usageOK) 190 return errorSyntax( USAGE_GUESTPROPERTY,GuestProp::tr("Incorrect parameters"));177 return errorSyntax(GuestProp::tr("Incorrect parameters")); 191 178 /* This is always needed. */ 192 179 pszName = a->argv[1]; … … 221 208 static RTEXITCODE handleEnumGuestProperty(HandlerArg *a) 222 209 { 210 setCurrentSubcommand(HELP_SCOPE_GUESTPROPERTY_ENUMERATE); 211 223 212 /* 224 213 * Check the syntax. We can deduce the correct syntax from the number of … … 230 219 && strcmp(a->argv[1], "--patterns") 231 220 && strcmp(a->argv[1], "-patterns"))) 232 return errorSyntax( USAGE_GUESTPROPERTY,GuestProp::tr("Incorrect parameters"));221 return errorSyntax(GuestProp::tr("Incorrect parameters")); 233 222 234 223 /* … … 283 272 static RTEXITCODE handleWaitGuestProperty(HandlerArg *a) 284 273 { 274 setCurrentSubcommand(HELP_SCOPE_GUESTPROPERTY_WAIT); 275 285 276 /* 286 277 * Handle arguments … … 317 308 } 318 309 if (!usageOK) 319 return errorSyntax( USAGE_GUESTPROPERTY,GuestProp::tr("Incorrect parameters"));310 return errorSyntax(GuestProp::tr("Incorrect parameters")); 320 311 321 312 /* … … 420 411 421 412 if (a->argc == 0) 422 return errorSyntax( USAGE_GUESTPROPERTY,GuestProp::tr("Incorrect parameters"));413 return errorSyntax(GuestProp::tr("Incorrect parameters")); 423 414 424 415 /* switch (cmd) */ … … 435 426 436 427 /* default: */ 437 return errorSyntax( USAGE_GUESTPROPERTY,GuestProp::tr("Incorrect parameters"));428 return errorSyntax(GuestProp::tr("Incorrect parameters")); 438 429 } 439 430 -
trunk/src/VBox/Frontends/VBoxManage/VBoxManageHelp.cpp
r94207 r94208 639 639 "\n", SEP); 640 640 641 #ifdef VBOX_WITH_GUEST_PROPS642 if (enmCommand == USAGE_GUESTPROPERTY || enmCommand == USAGE_S_ALL)643 usageGuestProperty(pStrm, SEP);644 #endif /* VBOX_WITH_GUEST_PROPS defined */645 646 641 #ifdef VBOX_WITH_GUEST_CONTROL 647 642 if (enmCommand == USAGE_GUESTCONTROL || enmCommand == USAGE_S_ALL)
Note:
See TracChangeset
for help on using the changeset viewer.