Update install debian script
This commit is contained in:
		
							parent
							
								
									8ad6b3e191
								
							
						
					
					
						commit
						68ad39a468
					
				|  | @ -1,19 +1,10 @@ | ||||||
| #!/bin/bash | #!/bin/bash | ||||||
| # install packages I need | # install packages I need | ||||||
| sudo apt update | sudo apt update | ||||||
| sudo apt install -y nala |  | ||||||
| sudo apt install -y \ | sudo apt install -y \ | ||||||
| xorg                         `# for graphics` \ | xserver-xorg                 `# for graphics` \ | ||||||
|  | i3                           `# for graphics` \ | ||||||
| x11-xserver-utils            `# for graphics` \ | x11-xserver-utils            `# for graphics` \ | ||||||
| make                         `# for compiling gui` \ |  | ||||||
| gcc                          `# for compiling gui` \ |  | ||||||
| libx11-dev                   `# for compiling dwm` \ |  | ||||||
| libxft-dev                   `# for compiling dwm` \ |  | ||||||
| libxinerama-dev              `# for compiling dwm` \ |  | ||||||
| libharfbuzz-dev              `# for compiling st` \ |  | ||||||
| libimlib2-dev                `# for compiling st` \ |  | ||||||
| suckless-tools               `# for dmenu` \ |  | ||||||
| ncdu                         `# for disk usage analysys` \ |  | ||||||
| brightnessctl                `# for keyboard backlight` \ | brightnessctl                `# for keyboard backlight` \ | ||||||
| xcompmgr                     `# for st opacity` \ | xcompmgr                     `# for st opacity` \ | ||||||
| mate-backgrounds             `# for background` \ | mate-backgrounds             `# for background` \ | ||||||
|  | @ -22,51 +13,29 @@ pulseaudio                   `# for sound` \ | ||||||
| pavucontrol                  `# for audio control` \ | pavucontrol                  `# for audio control` \ | ||||||
| pasystray                    `# for audio control` \ | pasystray                    `# for audio control` \ | ||||||
| iputils-ping                 `# ping etc.` \ | iputils-ping                 `# ping etc.` \ | ||||||
| xfe                          `# classic file manager` \ |  | ||||||
| surf                         `# suckless lightweight browser` \ |  | ||||||
| micro                        `# console editor` \ |  | ||||||
| neovim                       `# console editor` \ | neovim                       `# console editor` \ | ||||||
| psmisc                       `# pstree etc.` \ | psmisc                       `# pstree etc.` \ | ||||||
|  | software-properties-common   `# manage repos (needed for nvidia-drivers installation)` \ | ||||||
| chromium \ | chromium \ | ||||||
|  | telegram-desktop \ | ||||||
| python3 \ | python3 \ | ||||||
| python3-venv  | python3-venv  | ||||||
| 
 | 
 | ||||||
| # install telegram | cat > ~/.xinitrc << EOL | ||||||
| if [ ! -d /opt/Telegram ] | dbus-update-activation-environment --systemd DBUS_SESSION_BUS_ADDRESS DISPLAY XAUTHORITY & # because of slow Telegram start | ||||||
| then	 | xcompmgr & # for st opacity | ||||||
|   if [ ! -f telegram.tar.xz ] | image=$(find /usr/share/backgrounds/mate/nature/ -type f | sort --random-sort | head -1) | ||||||
|   then | xwallpaper --stretch $image | ||||||
|   	curl -L https://telegram.org/dl/desktop/linux -o telegram.tar.xz | conky & | ||||||
|   fi	 | i3 | ||||||
|   tar -xf telegram.tar.xz | EOL | ||||||
|   rm -f telegram.tar.xz |  | ||||||
|   sudo mv Telegram /opt/ |  | ||||||
| fi |  | ||||||
| 
 | 
 | ||||||
| # remove autoinstalled stterm | sudo add-apt-repository contrib non-free-firmware | ||||||
| sudo apt remove stterm -y | sudo apt update | ||||||
|  | sudo apt install linux-headers-amd64 nvidia-driver linux-image-amd64 | ||||||
| 
 | 
 | ||||||
| mkdir ~/Development || true |  | ||||||
| if [ ! -d ~/Development/gui ] |  | ||||||
| then |  | ||||||
|   git clone https://git.digitalstudium.com/digitalstudium/ubuntu-gui ~/Development/gui |  | ||||||
| fi |  | ||||||
| 
 | 
 | ||||||
| for tool in dwm st sent | for tool in create_systemd_service.py create_systemd_timer.py set_brightness.sh | ||||||
| do     |  | ||||||
|   # compiling dwm |  | ||||||
|   if ! command -v $tool &> /dev/null |  | ||||||
|   then |  | ||||||
|     cd ~/Development/gui/$tool |  | ||||||
|     sudo make install clean |  | ||||||
|     cd - |  | ||||||
|   fi   |  | ||||||
| done |  | ||||||
| 
 |  | ||||||
| echo 'dbus-update-activation-environment --systemd DBUS_SESSION_BUS_ADDRESS DISPLAY XAUTHORITY &' > ~/.xinitrc  # because of slow Telegram start |  | ||||||
| echo dwm >> ~/.xinitrc  # for starting dwm when startx |  | ||||||
| 
 |  | ||||||
| for tool in create_systemd_service.py create_systemd_timer.py set_brightness.sh update_gui.sh |  | ||||||
| do     | do     | ||||||
|   if ! command -v $tool &> /dev/null |   if ! command -v $tool &> /dev/null | ||||||
|   then |   then | ||||||
|  | @ -77,23 +46,7 @@ done | ||||||
| git config --global user.name "Digital Studium" | git config --global user.name "Digital Studium" | ||||||
| git config --global user.email "digitalstudium001@gmail.com" | git config --global user.email "digitalstudium001@gmail.com" | ||||||
| 
 | 
 | ||||||
| sudo create_systemd_service.py gui-updater /usr/local/bin/update_gui.sh |  | ||||||
| sudo create_systemd_timer.py gui-updater '*-*-* *:*:*' |  | ||||||
| 
 |  | ||||||
| if [ ! -d ~/.dwm ] |  | ||||||
| then |  | ||||||
|   mkdir $HOME/.dwm |  | ||||||
| fi   |  | ||||||
| echo "xhost +local:" > $HOME/.dwm/autostart.sh # give permissions to display |  | ||||||
| echo "xcompmgr &" >> $HOME/.dwm/autostart.sh  # for st opacity |  | ||||||
| echo "xwallpaper --stretch /usr/share/backgrounds/mate/nature/Dune.jpg" >> $HOME/.dwm/autostart.sh  # background |  | ||||||
| echo "chromium &" >> $HOME/.dwm/autostart.sh |  | ||||||
| echo "Telegram &" >> $HOME/.dwm/autostart.sh |  | ||||||
| echo "st &" >> $HOME/.dwm/autostart.sh |  | ||||||
| echo "pasystray &" >> $HOME/.dwm/autostart.sh |  | ||||||
| chmod +x $HOME/.dwm/autostart.sh |  | ||||||
| 
 |  | ||||||
| sudo timedatectl set-timezone Europe/Moscow | sudo timedatectl set-timezone Europe/Moscow | ||||||
| 
 | 
 | ||||||
| sudo bash -c "echo 'PATH=\$(find /opt/ -executable -type f | grep -v \.so | xargs dirname | uniq | paste -s -d : | xargs -I _ echo \$PATH:_)' > /etc/profile.d/opt.sh" | sudo bash -c "echo 'PATH=\$PATH:\$(find /opt/ -executable -type f | grep -v \.so | xargs dirname | uniq | paste -s -d : | xargs -I _ echo _)' > /etc/profile.d/opt.sh" | ||||||
| 
 | 
 | ||||||
|  |  | ||||||
		Loading…
	
		Reference in New Issue