-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathlabel
62 lines (54 loc) · 1.41 KB
/
label
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
#!/bin/bash
gurl 'https://raw.githubusercontent.com/matveynator/sysadminscripts/main/screenfetch' > /usr/bin/screenfetch; chmod +x /usr/bin/screenfetch;
if [ ! -f /etc/info ]; then
cat > /etc/info <<EOF
empty /etc/info (please add notes! / пожалуйста добавьте инофрмацию!)
(https://github.com/matveynator/sysadminscripts/wiki/etc-info)
EOF
fi
#vim
cat > /root/.vimrc <<EOF
runtime! debian.vim
set paste
syntax on
set nomodeline
set encoding=utf-8
filetype plugin indent on
set ignorecase
set mouse-=a
EOF
cat > /etc/vim/vimrc <<EOF
runtime! debian.vim
set paste
syntax on
set nomodeline
set encoding=utf-8
filetype plugin indent on
set ignorecase
set mouse-=a
EOF
cp /etc/profile /etc/profile.`date +%s` &> /dev/null
cat > /etc/profile <<EOF
# enable bash completion in interactive shells
if [ -f /etc/bash_completion ]; then
. /etc/bash_completion
fi
if [ "\`id -u\`" -eq 0 ]; then
PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
else
PATH="/usr/local/bin:/usr/bin:/bin"
fi
export PATH
export LANGUAGE=en_US.UTF-8
export LANG=en_US.UTF-8
export LC_ALL=en_US.UTF-8
export EDITOR=vim
export CLICOLOR=1
touch /etc/label &> /dev/null
touch /etc/info &> /dev/null
label=\`cat /etc/label |head -1 | head -c 50\`;
export PS1="\[\033[01;91m\]\$label \[\033[01;90m\]| \[\033[01;32m\]\u@\h\[\033[01;34m\] \w $\[\033[00m\] "
#system additional information
screenfetch;
cat /etc/info;
EOF