Some changes
This commit is contained in:
parent
275f75b561
commit
9beb3f0c50
55
install-debian.sh
Executable file → Normal file
55
install-debian.sh
Executable file → Normal file
@ -2,8 +2,10 @@
|
|||||||
|
|
||||||
# functions
|
# functions
|
||||||
function repository {
|
function repository {
|
||||||
add-apt-repository -y ppa:ultradvorka/ppa
|
apt-get install -y software-properties-common && (
|
||||||
add-apt-repository -y ppa:webupd8team/java
|
add-apt-repository -y ppa:ultradvorka/ppa
|
||||||
|
add-apt-repository -y ppa:webupd8team/java
|
||||||
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
function update-upgrade {
|
function update-upgrade {
|
||||||
@ -13,30 +15,31 @@ function update-upgrade {
|
|||||||
|
|
||||||
function common {
|
function common {
|
||||||
# default shell
|
# default shell
|
||||||
apt-get install -y sudo tmux mc tree pv vim mosh bash-completion
|
apt-get install -y sudo mc tree pv vim mosh bash-completion
|
||||||
|
|
||||||
# bash shell
|
# bash shell
|
||||||
apt-get install -y hh
|
apt-get install -y hh && (
|
||||||
grep HH_CONFIG /etc/bash.bashrc || \
|
grep HH_CONFIG /etc/bash.bashrc || \
|
||||||
hh --show-configuration >> /etc/bash.bashrc
|
hh --show-configuration >> /etc/bash.bashrc
|
||||||
|
)
|
||||||
|
|
||||||
# zsh shell
|
# zsh shell
|
||||||
apt-get install -y zsh
|
apt-get install -y zsh && (
|
||||||
sed 's/\/bin\/bash/\/bin\/zsh/' /etc/passwd > /tmp/passwd
|
sed -i -- 's/\/bin\/bash/\/bin\/zsh/' /etc/passwd
|
||||||
mv -f /tmp/passwd /etc/passwd
|
wget -O /etc/zsh/newuser.zshrc.recommended \
|
||||||
rm -f /tmp/passwd
|
http://git.grml.org/f/grml-etc-core/etc/zsh/zshrc
|
||||||
wget -O /etc/zsh/newuser.zshrc.recommended \
|
root_user=$(grep ':0:' /etc/passwd | awk -F':' '{print $6}')
|
||||||
http://git.grml.org/f/grml-etc-core/etc/zsh/zshrc
|
default_user=$(grep ':1000:' /etc/passwd | awk -F':' '{print $6}')
|
||||||
root_user=$(grep ':0:' /etc/passwd | awk -F':' '{print $6}')
|
cp -f /etc/zsh/newuser.zshrc.recommended $default_user/.zshrc
|
||||||
default_user=$(grep ':1000:' /etc/passwd | awk -F':' '{print $6}')
|
cp -f /etc/zsh/newuser.zshrc.recommended $root_user/.zshrc
|
||||||
cp -f /etc/zsh/newuser.zshrc.recommended $default_user/.zshrc
|
)
|
||||||
cp -f /etc/zsh/newuser.zshrc.recommended $root_user/.zshrc
|
|
||||||
|
|
||||||
# tmux
|
# tmux
|
||||||
echo 'if [ "$TMUX" = "" ]; then tmux; fi' | cat - $default_user/.zshrc > \
|
apt-get install -y tmux && (
|
||||||
/tmp/.zshrc && mv /tmp/.zshrc $default_user/.zshrc
|
default_user=$(grep ':1000:' /etc/passwd | awk -F':' '{print $6}')
|
||||||
echo 'if [ "$TMUX" = "" ]; then tmux; fi' | cat - $root_user/.zshrc > \
|
echo 'if [ "$TMUX" = "" ]; then tmux; fi' | cat - $default_user/.zshrc > \
|
||||||
/tmp/.zshrc && mv /tmp/.zshrc $root_user/.zshrc
|
/tmp/.zshrc && mv /tmp/.zshrc $default_user/.zshrc
|
||||||
|
)
|
||||||
|
|
||||||
# diagnostics
|
# diagnostics
|
||||||
apt-get install -y htop iotop iftop nmon powertop stress lm-sensors \
|
apt-get install -y htop iotop iftop nmon powertop stress lm-sensors \
|
||||||
@ -46,7 +49,7 @@ function common {
|
|||||||
apt-get install -y git subversion libapache2-svn build-essential
|
apt-get install -y git subversion libapache2-svn build-essential
|
||||||
|
|
||||||
# networking
|
# networking
|
||||||
apt-get install -y nfs-common cifs-utils aircrack-ng openvpn axel \
|
apt-get install -y nfs-common cifs-utils openvpn axel \
|
||||||
wget ethtool fping
|
wget ethtool fping
|
||||||
|
|
||||||
# misc. tools
|
# misc. tools
|
||||||
@ -89,8 +92,8 @@ function client-gui {
|
|||||||
}
|
}
|
||||||
|
|
||||||
function client-gui-end {
|
function client-gui-end {
|
||||||
# Java Plugin
|
# Java Plugin
|
||||||
update-alternatives --config mozilla-javaplugin.so
|
update-alternatives --config mozilla-javaplugin.so
|
||||||
}
|
}
|
||||||
|
|
||||||
function server-gui {
|
function server-gui {
|
||||||
@ -120,8 +123,8 @@ select opt in "${options[@]}"
|
|||||||
do
|
do
|
||||||
case $opt in
|
case $opt in
|
||||||
"client-gui")
|
"client-gui")
|
||||||
repository
|
|
||||||
update-upgrade
|
update-upgrade
|
||||||
|
repository
|
||||||
common
|
common
|
||||||
client-gui
|
client-gui
|
||||||
common-end
|
common-end
|
||||||
@ -129,16 +132,16 @@ do
|
|||||||
break
|
break
|
||||||
;;
|
;;
|
||||||
"server-cli")
|
"server-cli")
|
||||||
repository
|
|
||||||
update-upgrade
|
update-upgrade
|
||||||
|
repository
|
||||||
common
|
common
|
||||||
server-cli
|
server-cli
|
||||||
common-end
|
common-end
|
||||||
break
|
break
|
||||||
;;
|
;;
|
||||||
"server-gui")
|
"server-gui")
|
||||||
repository
|
|
||||||
update-upgrade
|
update-upgrade
|
||||||
|
repository
|
||||||
common
|
common
|
||||||
server-gui
|
server-gui
|
||||||
common-end
|
common-end
|
||||||
|
Loading…
x
Reference in New Issue
Block a user