void print_sorted_export(t_env *env)
Print all env vars sorted in alphabetical order, in declare -x format.
int builtin_echo(char **args)
Implement the echo command.
int builtin_cd(char **args, t_env **env)
Implement the cd command.
void export_no_value(t_env **env, char *key)
Export a variable with no value (export KEY)
void export_assign(t_env **env, char *arg)
Export a variable with a value (export KEY=value)
int builtin_unset(char **args, t_env **env)
Implement the unset command.
int builtin_env(char **args, t_env *env)
Implement the env command.
int builtin_exit(char **args, t_shell *shell)
Implement the exit command.
int builtin_pwd(void)
Implement the pwd command.
int builtin_export(char **args, t_env **env)
Implement the export command.
void export_append(t_env **env, char *arg)
Export a variable with append (export KEY+=value)
Central type definitions for mandatory part.
Environment variable (doubly linked list)