Open jovanbulck opened 10 years ago
Some extra info on this:
documentation:
env
command prints all environment variables that it is passed --> great for testingset
shell built_in command (but I think we don't need to implement this for now?)On export
: wikipedia says:
"In Unix shells, variables may be assigned without the export keyword. Variables defined in this way are displayed by the set command, but are not true environment variables, as they are stored only by the shell and not recognized by the kernel. The printenv command will not display them, and child processes do not inherit them."
setenv(3)
when export
is supplied.setenv(3)
syscall will then update the table and the variable will automatically be passed to the child. e.g. as is done in the cd
built_in for the PWD
env var~
alias)? or is this context sensitive, as normal aliases? => I'm not sure, but I think this might be context insensitive, allowing 'easy' substitution. Share your thoughts...unsetenv <name> <value>
built_in that calls unsetenv(1)
things todo:
setenv <name> <value>
built_in that callssetenv(3)
extern
keywordenv_var="value"
instead ofenv env_var "value"
?