File tree Expand file tree Collapse file tree 2 files changed +28
-0
lines changed Expand file tree Collapse file tree 2 files changed +28
-0
lines changed Original file line number Diff line number Diff line change @@ -71,6 +71,7 @@ aptitude -y install git
71
71
aptitude -y install gitk
72
72
aptitude -y install subversion
73
73
aptitude -y install mysql-server
74
+ aptitude -y install sysklogd
74
75
# aptitude -y install arduino
75
76
# aptitude -y install eclipse-jdt
76
77
# aptitude -y install python-pip
Original file line number Diff line number Diff line change
1
+ # usage: install this file to /etc/profile.d/ or add to /etc/profile
2
+ export HISTTIMEFORMAT=" %y-%m-%d %H:%M:%S "
3
+ PS1=" ` whoami` @` hostname` :" ' [$PWD]'
4
+
5
+ history
6
+ USER_IP=` who -u am i 2> /dev/null | awk ' {print $NF}' | sed -e ' s/[()]//g' `
7
+
8
+ if [ " X$USER_IP " == " X:0" ]; then
9
+ USER_IP=` hostname`
10
+ elif [ " X$USER_IP " == " X" ]; then
11
+ USER_IP=` hostname`
12
+ fi
13
+
14
+ if [ ! -d " /tmp/history" ]; then
15
+ mkdir /tmp/history
16
+ chmod 777 /tmp/history
17
+ fi
18
+
19
+ if [ ! -d /tmp/history/${LOGNAME} ]; then
20
+ mkdir /tmp/history/${LOGNAME}
21
+ chmod 300 /tmp/history/${LOGNAME}
22
+ fi
23
+
24
+ export HISTSIZE=4096
25
+ DT=$( date +" %Y%m%d_%H%M%S" )
26
+ export HISTFILE=" /tmp/history/${LOGNAME} /${USER_IP} _history.$DT "
27
+ chmod 600 /tmp/history/${LOGNAME} /* history* 2> /dev/null
You can’t perform that action at this time.
0 commit comments