cd ok et appel a path dans export
This commit is contained in:
@@ -1,10 +1,15 @@
|
||||
|
||||
#include "minishell.h"
|
||||
|
||||
// a integrer dans header
|
||||
char *init_prompt(char *prompt_base);
|
||||
|
||||
int builtin_cd(int argc, char *argv[], t_all *c)
|
||||
{
|
||||
(void)argc;
|
||||
(void)c;
|
||||
chdir(argv[1]);
|
||||
c->prompt = init_prompt(c->prompt_base);
|
||||
if (!c->prompt)
|
||||
return (ft_reti_perror(0, "init_prompt() error"));
|
||||
return (0);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user