|
11 | 11 |
|
12 | 12 | #define BUFFER_SIZE 1024
|
13 | 13 |
|
14 |
| -extern char** environ; |
| 14 | +extern char **environ; |
15 | 15 |
|
16 |
| -int main(int argc, char *argv[], char **env); |
17 |
| -char **tokenize(char *buffer, const char *delim); |
| 16 | +/*....... Path finders.......*/ |
| 17 | +int main(int argc, char __attribute__((__unused__)) *argv[], char **env); |
18 | 18 | char *locate_path(char *com_val);
|
19 |
| -char *_getline(); |
| 19 | +int execute_command(char *get_address, char __attribute__((__unused__)) **env); |
20 | 20 |
|
| 21 | +/*........Tokenizers......*/ |
| 22 | +char **tokenize(char *buffer, const char *delim); |
| 23 | +char *_strtok(char *str, const char *fem); |
| 24 | +unsigned int find_delim(char n, const char *str); |
21 | 25 |
|
22 |
| -int _execute(char *args, char **envp); |
| 26 | +/*........ Environ variables.......*/ |
23 | 27 |
|
| 28 | +char *_getenv(const char *str); |
| 29 | +ssize_t read_input(char **get_address, size_t *length_input); |
| 30 | +void _printenv(void); |
24 | 31 |
|
25 |
| -/*....... String Handlers.....*/ |
| 32 | +/*.......... String Handlers.........*/ |
26 | 33 | void int_to_string(int value, char *result);
|
27 |
| -int _putchar(char c); |
28 | 34 | int _strcmp(char *s1, char *s2);
|
29 |
| -int _strncmp(const char *s1, const char *s2, size_t k); |
30 | 35 | char *_strcat(char *dest, const char *src);
|
31 |
| -void _puts(char *str); |
| 36 | +int _strncmp(const char *s1, const char *s2, size_t s); |
32 | 37 | int _strlen(const char *s);
|
33 | 38 | char *_strcpy(char *dest, char *src);
|
34 | 39 | int _atoi(char *s);
|
35 |
| -char *_strndup(char *s); |
| 40 | +char *_strdup(char *s); |
36 | 41 |
|
37 |
| -/*..... Environments handlers....*/ |
38 |
| -char **_getenv(const char *str); |
39 |
| -int prog_setenv(char **args, char __attribute__((__unused__)) **ard); |
40 |
| -int prog_unsetenv(char **args, char __attribute__((__unused__)) **ard); |
41 |
| -void _printenv(void); |
42 |
| -void print_env_variable(const char *str); |
43 |
| - |
44 |
| -/*........MISCELLINEOUS...*/ |
45 |
| -unsigned int find_delim(char n, const char *str); |
46 |
| -void _error(const char *args, int error_msg); |
| 42 | +/*....... Miscillenous....*/ |
| 43 | +int execute_and_wait(char *command_path, char **tokens, int *e_status); |
47 | 44 |
|
48 | 45 | #endif
|
0 commit comments