82 goto err_parse_options;
95 goto err_create_dynui;
145 "[<name> [<text>]]" );
158 unsigned int flags = 0;
165 goto err_parse_options;
182 goto err_parse_dynui;
185 if (
opts.is_default )
187 if (
opts.is_secret )
193 goto err_add_dynui_item;
255 goto err_parse_options;
260 goto err_parse_setting;
264 goto err_parse_dynui;
268 opts.select, &item ) ) != 0 )
277 item->
name ) ) != 0 ) {
278 printf (
"Could not store \"%s\": %s\n",
331 goto err_parse_options;
335 goto err_parse_dynui;
#define NULL
NULL pointer (VOID *)
union @162305117151260234136356364136041353210355154177 key
Sense key.
struct arbelprm_rc_send_wqe rc
static union @024010030001061367220137227263210031030210157031 opts
"cert<xxx>" option list
#define COMMAND(name, exec)
void destroy_dynui(struct dynamic_ui *dynui)
Destroy dynamic user interface.
struct dynamic_ui * create_dynui(const char *name, const char *title)
Create dynamic user interface.
struct dynamic_item * add_dynui_item(struct dynamic_ui *dynui, const char *name, const char *text, unsigned int flags, int shortcut)
Add dynamic user interface item.
#define DYNUI_DEFAULT
Dynamic user interface item is default selection.
#define DYNUI_SECRET
Dynamic user interface item represents a secret.
static struct option_descriptor choose_opts[]
"choose" option list
static struct command_descriptor present_cmd
"present" command descriptor
static struct command_descriptor item_cmd
"item" command descriptor
static struct option_descriptor present_opts[]
"present" option list
static int item_exec(int argc, char **argv)
The "item" command.
static struct command_descriptor dynui_cmd
"dynui" command descriptor
static struct command_descriptor choose_cmd
"choose" command descriptor
static struct option_descriptor dynui_opts[]
"dynui" option list
static int dynui_exec(int argc, char **argv)
The "dynui" command.
static int present_exec(int argc, char **argv)
The "present" command.
static int choose_exec(int argc, char **argv)
The "choose" command.
static struct option_descriptor item_opts[]
"item" option list
char * concat_args(char **args)
Concatenate arguments.
int optind
Current option index.
Parse command-line options.
@ required_argument
Option requires an argument.
@ no_argument
Option does not take an argument.
#define DHCP_EB_FEATURE_MENU
Menu support.
#define FEATURE_MISC
Miscellaneous.
#define FILE_LICENCE(_licence)
Declare a particular licence as applying to a file.
#define ENOMEM
Not enough space.
#define FILE_SECBOOT(_status)
Declare a file's UEFI Secure Boot permission status.
#define FEATURE(category, text, feature_opt, version)
Declare a feature.
int parse_key(char *text, unsigned int *key)
Parse key.
int parse_flag(char *text __unused, int *flag)
Parse flag.
int parse_dynui(char *text, struct dynamic_ui **dynui)
Parse dynamic user interface name.
int parse_string(char *text, char **value)
Parse string value.
int parse_autovivified_setting(char *text, struct named_setting *setting)
Parse and autovivify setting name.
int parse_timeout(char *text, unsigned long *value)
Parse timeout value (in ms)
int parse_options(int argc, char **argv, struct command_descriptor *cmd, void *opts)
Parse command-line options.
Command line option parsing.
#define MAX_ARGUMENTS
No maximum number of arguments.
#define COMMAND_DESC(_struct, _options, _min_args, _max_args, _usage)
Construct command descriptor.
#define OPTION_DESC(_longopt, _shortopt, _has_arg, _struct, _field, _parse)
Construct option descriptor.
int select(fd_set *readfds, int wait)
Check file descriptors for readiness.
static void(* free)(struct refcnt *refcnt))
int storef_setting(struct settings *settings, const struct setting *setting, const char *value)
Store formatted value of setting.
char * strerror(int errno)
Retrieve string representation of error number.
char * dynui
Dynamic user interface name.
unsigned long retimeout
Post-activity timeout.
int keep
Keep dynamic user interface.
unsigned long timeout
Initial timeout.
char * select
Default selection.
A dynamic user interface item.
A dynamic user interface.
int is_secret
Value is a secret.
int is_gap
Use as a separator.
char * dynui
Dynamic user interface name.
int is_default
Use as default.
unsigned int key
Shortcut key.
A command-line option descriptor.
char * dynui
Dynamic user interface name.
int keep
Keep dynamic user interface.
const struct setting_type * type
Setting type.
int printf(const char *fmt,...)
Write a formatted string to the console.