-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathman_1_simple_shell
91 lines (78 loc) · 1.59 KB
/
man_1_simple_shell
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
.TH hsh 1 "August 2022" "1.0" "ALX simple_shell Manual"
.SH NAME
hsh \- Simple UNIX shell
.SH SYNOPSIS
.B ./hsh
.I options are not available
Part of a project at alx school.
.SH DESCRIPTION
hsh is a simplified shell that takes user input as UNIX commands and interprets\
them. It based on the first UNIX shell created by Ken Thompson. It is designed\
to be used in a UNIX-like environment.
.SH INVOCATION
.br
.\&
.RS
\&$ ./hsh
A prompt will then appear and the user can begin entering and executing\
commands by pressing 'enter'.
Commands can also be entered and then piped into ./hsh.
.br
.\&
\&$ echo "I have a purple penguin" | ./hsh
.SH FEATURES
.br
.B Accepts piped input
.br
.B Accepts file as an argument
.br
.B Variable substitution
.br
-$? $$ $# $0-9
.br
.B Set local vars with FOO=bar
.br
-Local variables not passed with environment
.br
.B escape characters with -&&, || and ; -tilde expansion to home \
directory from env
.SH BUILTINS
The following builtins are supported by hsh
.br
.br
.B env
.br
-prints environment.Falls through to std env if more than 1 arg -quotes around\
arguments (accepting more stdin on mismatch in progress)
.br
.B exit
-with status
.br
-exits the program
.br
.B cd
.br
- change directories
.br
.B setenv
.br
- sets environment variable
.br
.B unsetenv
.br
- unsets environment variable
.br
.B alias
.br
- creates alias variable
.br
.B unalias
.br
- removes alias variable
.SH BUGS
No known bugs, but hey we aren't perfect. Please report any bugs to the twitter\
accounts @4mcking or @davidmusembi
.SH "SEE ALSO"
.SH sh
.SH "AUTHORS"
Kingson Emma-Ochu and David Musembi