iPXE
|
Minimal command shell. More...
#include <stdint.h>
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
#include <getopt.h>
#include <readline/readline.h>
#include <ipxe/command.h>
#include <ipxe/parseopt.h>
#include <ipxe/shell.h>
#include <config/branding.h>
Go to the source code of this file.
Data Structures | |
struct | shell_options |
"shell" options More... | |
Functions | |
FILE_LICENCE (GPL2_OR_LATER_OR_UBDL) | |
static int | help_exec (int argc __unused, char **argv __unused) |
"help" command More... | |
int | shell (void) |
Start command shell. More... | |
static int | shell_exec (int argc, char **argv) |
"shell" command More... | |
Variables | |
static const char | shell_prompt [] = PRODUCT_SHORT_NAME "> " |
The shell prompt string. More... | |
struct command help_command | __command |
"help" command More... | |
static struct option_descriptor | shell_opts [] = {} |
"shell" option list More... | |
static struct command_descriptor | shell_cmd |
"shell" command descriptor More... | |
Minimal command shell.
Definition in file shell.c.
FILE_LICENCE | ( | GPL2_OR_LATER_OR_UBDL | ) |
|
static |
"help" command
argc | Argument count |
argv | Argument list |
rc | Return status code |
Definition at line 53 of file shell.c.
References command, COMMANDS, for_each_table_entry, command::name, and printf().
int shell | ( | void | ) |
Start command shell.
Definition at line 84 of file shell.c.
References free, history_free(), memset(), NULL, rc, readline_history(), shell_prompt, SHELL_STOP_COMMAND_SEQUENCE, shell_stopped(), and system.
Referenced by interrupt(), ipxe(), and shell_exec().
|
static |
"shell" command
argc | Argument count |
argv | Argument list |
rc | Return status code |
Definition at line 124 of file shell.c.
References opts, parse_options(), rc, shell(), and shell_cmd.
|
static |
struct command shell_command __command |
"help" command
"shell" command
|
static |
|
static |
"shell" command descriptor
Definition at line 114 of file shell.c.
Referenced by shell_exec().