This project is about creating a simple shell. Well it's not that simple!
SMBASH
Go to content | Date YYYY-MM-DD | Description |
---|---|---|
2022-06-17 | methodology alignment | |
2022-06-15 | init README |
:warning: The readline() function can cause memory leaks. You don’t have to fix them. But that doesn’t mean your own code, yes the code you wrote, can have memory leaks.
The command allows you to run another program in a custom environment without modifying the current one. When used without an argument it will print a list of the current environment variables.
:warning The command will change the env list only for the active command no matters if several pipes
:pushpin: Normal behaviour of env process if pipe due to fork which duplicates the vqriqbles before to execute the commqnd
env
env ENV_NAME=value
env ENV_NAME=value <command>
ENV_NAME=value
export antho=cia
export al$antho=tata
env | sort | grep 'al'
alicia=tata
:warning: ENV_NAME is case sensitive
:warning: append existing variable which does not exist will create it only during the flow of command if command argument exists
The command sets environment variables.
:warning The command will change the env list only for the active command only if several pipes. Otherwise the env list is changed
:pushpin: Normal behaviour of export process if pipe due to fork which duplicates the vqriqbles before to execute the commqnd
Example:
export ANTHO=tata
==> will update/create the env AMTHO into the env listexport ANTHO=tata | echo $ANTHO
==> will update/create the env ANTHO only for the active command
export
export ENV_NAME=value
export ENV_NAME=$EXISTING_ENV:value
declare -x ENV_NAME=value
export antho=cia
export al$antho=tata
env | sort | grep 'al'
alicia=tata
:warning: ENV_NAME is case sensitive
:warning: append existing variable which does not exist will create it
readline, rl_clear_history, rl_on_new_line,
rl_replace_line, rl_redisplay, add_history,
printf, malloc, free, write, access, open, read,
close, fork, wait, waitpid, wait3, wait4, signal,
sigaction, sigemptyset, sigaddset, kill, exit,
getcwd, chdir, stat, lstat, fstat, unlink, execve,
dup, dup2, pipe, opendir, readdir, closedir,
strerror, perror, isatty, ttyname, ttyslot, ioctl,
getenv, tcsetattr, tcgetattr, tgetent, tgetflag,
tgetnum, tgetstr, tgoto, tputs
:mag: To learn
:mag: To learn
:mag: To learn
:mag: To learn
:mag: To learn
:mag: To learn
:mag: To learn
:mag: To learn
:mag: To learn
:mag: To learn
:mag: Use to check permission right on object (files/directory) :video_game: pipex Link
:mag: To learn
:mag: To learn
:mag: To learn
:mag: Use to clone the active process to a child process :video_game: pipex Link
:mag: Use to wait a specific process :video_game: pipex Link
:mag: Use to wait a specific process :video_game: pipex Link
:mag: Obsolete
:mag: Obsolete
:mag: Overview of signals Link
:mag: Examine and change a signal action Link
:mag: Initialize and empty a signal set Link
:mag: Add a signal to a signal set Link
:mag: To learn
:mag: To learn
:mag: To learn
:mag: To learn
:mag: To learn
:mag: To learn
:mag: To learn
:mag: To learn
:mag: Use to execute a command :video_game: pipex
:mag: Use to create a new file descriptor according to an existing one :video_game: pipex
:mag: Use to "replace" an existing file descriptor from another existing one :video_game: pipex
:mag: Use to create two new file descriptor which can communicate through different process :video_game: pipex
:mag: To learn
:mag: To learn
:mag: To learn
:mag: To learn
:mag: To learn
:mag: Test whether a file descriptor refers to a terminal
:mag: Return name of a terminal
:mag: Find the slot of the current user's terminal in some file
:mag: Control device. To learn
:mag: Get an environment variable
:mag: Set the parameters associated with the terminal Link
:mag: Get the parameters associated with the terminal Link
:mag: To learn -->WTF ?
:mag: To learn -->WTF ?
:mag: To learn -->WTF ?
:mag: To learn -->WTF ?
:mag: To learn -->WTF ?
:mag: To learn -->WTF ?