File: whatami

package info (click to toggle)
superd 0.0.3-4
  • links: PTS
  • area: main
  • in suites: etch, etch-m68k
  • size: 136 kB
  • ctags: 85
  • sloc: ansic: 721; makefile: 103; sh: 27
file content (36 lines) | stat: -rwxr-xr-x 502 bytes parent folder | download | duplicates (3)
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
#!/bin/sh

info=`uname -a`
iam=fixme

if test `echo $info | awk ' { print $1 }'` = SunOS
then
	iam="solaris"
fi

if test `echo $info | awk ' { print $1 }'` = linux
then
	iam="linux"
fi

if test `echo $info | awk ' { print $1 }'` = Linux
then
	iam="linux"
fi

if test `echo $info | awk ' { print $1 }'` = FreeBSD
then
        iam="bsd"
fi

if test `echo $info | awk ' { print $1 }'` = OpenBSD
then
        iam="bsd"
fi     

if test `echo $info | awk ' {print $1 }'` = GNU
then
	iam="gnu"
fi

echo $iam