-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathifthen.sh
More file actions
55 lines (55 loc) · 774 Bytes
/
ifthen.sh
File metadata and controls
55 lines (55 loc) · 774 Bytes
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
#!/bin/bash
#if pwd
#then
#echo "pwd worked."
#elif ls -al
#then
#echo "ls worked."
#else
#echo "All doesn't work."
#fi
#if [ -d ~/Desktop/CS/Shell ]
#then
# echo "Not null."
# cd ~/Desktop/CS/Shell
# ls
#else
# echo "Null."
#fi
#if [ -e ~/Desktop/CS/Shell/ifthen.sh ]
#then
# echo "Have it."
#else
# echo "Don't have."
#fi
#if [ -r ~/Desktop/CS/Shell/ifthen.sh ] && [ -d ~/Desktop/CS/Shell ]
#then
# echo "Can read it."
#else
# echo "Can't read it."
#fi
#a=10
#if (( $a**100 ))
#then
# echo ">"
#elif (( $a**2==100 ))
#then
# echo "="
#else
# echo "<"
#fi
#if [[ "ssda"==s* ]]
#then
# echo "Hi."
#else
# echo "Bye."
#fi
a="Vayne"
case $a in
Vayne | dasd)
echo "Welcome.";;
BB)
echo "BB.";;
*)
echo "Sorry.";;
esac