24 lines
361 B
C
24 lines
361 B
C
#include <stdio.h>
|
|
#include <stdlib.h>
|
|
#include "cmd_utils.h"
|
|
|
|
#define clear() printf("\033[H\033[J")
|
|
|
|
int main() {
|
|
int status_return = 0;
|
|
char *cmd;
|
|
char **args;
|
|
|
|
init_shell();
|
|
|
|
do {
|
|
cmd = read_input();
|
|
args = split_cmd(cmd);
|
|
status_return = reverse_execute(args);
|
|
|
|
free(cmd);
|
|
free(args);
|
|
} while(status_return != 255);
|
|
return EXIT_SUCCESS;
|
|
}
|