Minishell
|
Functions | |
char * | get_command_input (data_t *data, int *command, redirection_t *type) |
int | split_commands (data_t *data) |
Variables | |
const char | redirect_chars [4] = {'<', '>', '|', ';'} |
char * get_command_input | ( | data_t * | data, |
int * | command, | ||
redirection_t * | type ) |
Help split the commands to save them in the linked list by returning an array of strings that are each word in a single command. it does this by iterating over the strings till it find a redirect_char
data | Global data structure |
command | Index if the current command count |
type | Contains the variable where the command type is saved |
int split_commands | ( | data_t * | data | ) |
const char redirect_chars[4] = {'<', '>', '|', ';'} |