help change

This commit is contained in:
Jakub Adamski 2019-01-11 17:17:03 +01:00
parent 7efd27a635
commit 08b7d9962a
3 changed files with 20 additions and 7 deletions

View File

@ -3,14 +3,27 @@ Microshell Help
-------------
General info
Author= Jakub Adamski
Index number=s444341
Limits
Max length of line=1000
Max number of arguments=100
Max length of argument=100
-------------
Working commands
help - manual
exit - ends microshell
cd - changing directory
(nie dziala dla np ~/)
jak zrobie echo $HOME tez nie dziala
dodac informacje o limitach dlugosci albo zrobic
to dynamicznie
cd - changing directory
needs exacly 1 argument
prints error when more/less
spath:
help - shows help page
0 - turns off displaying current directory
1 - turns on displaying current directory
PATH commands
WARNING
dont use path shorcuts
example cd ~/
or echo $HOME
-------------
q to exit!

Binary file not shown.

View File

@ -106,7 +106,7 @@ int main (){
}
else if (!strcmp(argv[0], "help")){
if (fork() == 0){
execlp("cat", "cat", "help", NULL);
execlp("less", "less", "help", NULL);
perror("execlp");
exit(EXIT_FAILURE);
}