I understand.  I have always believed the spec was wrong to try and take over 
"-?" from apps.  What it wants to do for internal command help is certainly 
something that it should specify, but it should not fail to execute an 
application due to the arguments that are being passed to the app.

Because of this, the apps I write only recognize "/" as the switch character, 
so the user gets the help they are looking for if they invoke them with /h (or 
any other argument they do not recognize as valid, unless, of course they try 
"-?"; then they get no useful information at all :-().

As Ruiyu pointed out, the current spec makes providing an application to 
someone more complicated than it could otherwise be.

>-----Original Message-----
>From: Carsey, Jaben [mailto:jaben.car...@intel.com]
>Sent: Tuesday, September 15, 2015 9:43 AM
>To: Dailey, Jim; Ni, Ruiyu; edk2-devel@lists.01.org
>Cc: Carsey, Jaben
>Subject: RE: Proposal to let standalone UEFI shell application carry help
>inside .EFI instead of in .MAN file
>
>Jim,
>
>Currently the shell spec requires a man file and dictates that the shell
>API GetHelp() be used for help processing.
>
>This is a case where if that current usage would fail, can we have a
>fallback that extends beyond the behavior in the spec. I do not think
>this violates the spec, but simply goes past those requirements.
>
>We do not want to execute a command other than the built in help command.
>
>-Jaben
>
>> -----Original Message-----
>> From: edk2-devel [mailto:edk2-devel-boun...@lists.01.org] On Behalf Of 
>> jim_dai...@dell.com
>> Sent: Tuesday, September 15, 2015 6:02 AM
>> To: Ni, Ruiyu ; edk2-devel@lists.01.org
>> Subject: Re: [edk2] Proposal to let standalone UEFI shell application 
>> carry help inside .EFI instead of in .MAN file
>> Importance: High
>> 
>> Yes, except if the shell can't find the man file (or it is invalid), 
>> then the shell should simply execute the .efi and let it handle the 
>> command line (regardless of EFI_HII_PACKAGE_LIST_PROTOCOL_GUID, etc.).
>> 
>> Regards,
>> Jim
>> 
>> -----Original Message-----
>> From: edk2-devel [mailto:edk2-devel-boun...@lists.01.org] On Behalf Of 
>> Ni, Ruiyu
>> Sent: Monday, September 14, 2015 9:54 PM
>> To: edk2-devel@lists.01.org
>> Cc: Carsey, Jaben; chr...@hpe.com; Hale, Robert P; Rothman, Michael A
>> Subject: [edk2] Proposal to let standalone UEFI shell application 
>> carry help inside .EFI instead of in .MAN file
>> 
>> All,
>> UEFI Shell scandalizes the help message in spec level so that a 
>> standalone UEFI shell application can never get "-?" switch, instead 
>> the Shell core
>> (interpreter) detects the "-?" and finds .MAN file for that shell 
>> application in certain spec defined paths, then show the help 
>> extracted from that .MAN file.
>> 
>> But it means distributing a UEFI shell application not only means 
>> distributing a .EFI file but also distributing a .MAN file. If the 
>> text formatted .MAN file is corrupted (edited by user by mistake), or 
>> is missing (deleted by user by mistake), no help will be shown to user.
>> 
>> So I propose to embedded the help message inside the .EFI file in a PE 
>> resource section and the algorithm to find help for a standalone 
>> application is as following.
>> 
>> Search command.man file for valid help content If command.man exists 
>> and help content is valid:
>> Display the help
>> Else:
>> Load the command.efi (do not start it) Check whether the ImageHandle 
>> has EFI_HII_PACKAGE_LIST_PROTOCOL_GUID installed Check all strings in 
>> the HII packages to find a string which follows spec defined help 
>> format If the string
>> exists:
>> Display the help
>> Else:
>> Show "no Help"
>> 
>> Any comments, concerns?
>> 
>> 
>> Regards,
>> Ray
>> 
>> _______________________________________________
>> edk2-devel mailing list
>> edk2-devel@lists.01.org
>> https://lists.01.org/mailman/listinfo/edk2-devel
>> _______________________________________________
>> edk2-devel mailing list
>> edk2-devel@lists.01.org
>> https://lists.01.org/mailman/listinfo/edk2-devel
_______________________________________________
edk2-devel mailing list
edk2-devel@lists.01.org
https://lists.01.org/mailman/listinfo/edk2-devel

Reply via email to