Adaptations for school's computer
This commit is contained in:
		
							parent
							
								
									ba90c09552
								
							
						
					
					
						commit
						dbf954db9e
					
				
					 5 changed files with 28 additions and 24 deletions
				
			
		
							
								
								
									
										3
									
								
								bashrc
									
										
									
									
									
								
							
							
						
						
									
										3
									
								
								bashrc
									
										
									
									
									
								
							|  | @ -41,6 +41,9 @@ export HISTCONTROL=ignoreboth | ||||||
| export JAVA_FONTS=/usr/share/fonts/TTF | export JAVA_FONTS=/usr/share/fonts/TTF | ||||||
| export ANDROID_HOME=/opt/android-sdk | export ANDROID_HOME=/opt/android-sdk | ||||||
| 
 | 
 | ||||||
|  | if [ -z $XDG_CONFIG_HOME ]; then | ||||||
|  |     export XDG_CONFIG_HOME=$HOME/.config | ||||||
|  | fi | ||||||
| 
 | 
 | ||||||
| # Tweaks | # Tweaks | ||||||
| [[ $- != *i* ]] && return | [[ $- != *i* ]] && return | ||||||
|  |  | ||||||
|  | @ -1,7 +1,8 @@ | ||||||
| #!/bin/bash | #!/bin/bash | ||||||
| i3-msg workspace Lock | i3-msg workspace Lock | ||||||
| imgpath=$HOME/.cache/blurlock.png | imgpath=$(mktemp).png | ||||||
| scrot $imgpath | scrot "$imgpath" | ||||||
| convert $imgpath -blur 0x5 $imgpath | convert "$imgpath" -blur 0x5 "$imgpath" | ||||||
| i3lock -f -i $imgpath | i3lock -f -i "$imgpath" | ||||||
| i3-msg workspace back_and_forth | i3-msg workspace back_and_forth | ||||||
|  | rm "$imgpath" | ||||||
|  |  | ||||||
|  | @ -1,2 +1,2 @@ | ||||||
| #!/usr/bin/sh | #!/usr/bin/env sh | ||||||
| play -n synth sine E5 sine A4 remix 1-2 fade 0.5 1.2 0.5 2> /dev/null | play -n synth sine E5 sine A4 remix 1-2 fade 0.5 1.2 0.5 2> /dev/null | ||||||
|  |  | ||||||
|  | @ -10,14 +10,15 @@ function debloc-custom-cli { | ||||||
|     debloc-install vim exuberant-ctags |     debloc-install vim exuberant-ctags | ||||||
| 
 | 
 | ||||||
|     # Dev |     # Dev | ||||||
|     debloc-install build-essential cmake clang |     debloc-install build-essential cmake clang llvm git | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
| function debloc-custom { | function debloc-custom { | ||||||
|     debloc-custom-cli |     debloc-custom-cli | ||||||
| 
 | 
 | ||||||
|     # Desktop manager |     # Desktop manager | ||||||
|     debloc-install i3 dmenu dunst unclutter xautolock feh numlockx scrot |     debloc-install i3 i3lock dmenu dunst unclutter xautolock feh numlockx scrot imagemagick suckless-tools | ||||||
|  |     ln -s $DEBLOC_ROOT/bin/dmenu{.xft,} | ||||||
| 
 | 
 | ||||||
|     # qutebrowser |     # qutebrowser | ||||||
|     debloc-install python3-lxml python-tox python3-pyqt5 python3-pyqt5.qtwebkit python3-sip python3-jinja2 python3-pygments python3-yaml |     debloc-install python3-lxml python-tox python3-pyqt5 python3-pyqt5.qtwebkit python3-sip python3-jinja2 python3-pygments python3-yaml | ||||||
|  |  | ||||||
|  | @ -3,6 +3,7 @@ | ||||||
| ARCH=$(dpkg --print-architecture) | ARCH=$(dpkg --print-architecture) | ||||||
| DEBLOC_DB=$HOME/.config/debloc/$ARCH | DEBLOC_DB=$HOME/.config/debloc/$ARCH | ||||||
| DEBLOC_ROOT=$HOME/.debloc/$ARCH | DEBLOC_ROOT=$HOME/.debloc/$ARCH | ||||||
|  | DEBLOC_LD=$DEBLOC_ROOT/ld | ||||||
| 
 | 
 | ||||||
| if [ -z $DEBIAN_MIRROR ]; then | if [ -z $DEBIAN_MIRROR ]; then | ||||||
|     DEBIAN_MIRROR=$(cat /etc/apt/sources.list | grep '^deb ' | grep main | grep -v security | grep -v updates | grep -v backports) |     DEBIAN_MIRROR=$(cat /etc/apt/sources.list | grep '^deb ' | grep main | grep -v security | grep -v updates | grep -v backports) | ||||||
|  | @ -13,8 +14,8 @@ mkdir -p $DEBLOC_DB &> /dev/null | ||||||
| mkdir -p $DEBLOC_ROOT &> /dev/null | mkdir -p $DEBLOC_ROOT &> /dev/null | ||||||
| 
 | 
 | ||||||
| export PATH="$DEBLOC_ROOT/usr/bin:$DEBLOC_ROOT/usr/games/:$DEBLOC_ROOT/usr/lib/git-core:$PATH" | export PATH="$DEBLOC_ROOT/usr/bin:$DEBLOC_ROOT/usr/games/:$DEBLOC_ROOT/usr/lib/git-core:$PATH" | ||||||
| export LD_LIBRARY_PATH="$DEBLOC_ROOT/lib:$LD_LIBRARY_PATH" | export LD_LIBRARY_PATH="$DEBLOC_LD:$LD_LIBRARY_PATH" | ||||||
| export PYTHONPATH="$DEBLOC_ROOT/usr/lib/python3:$PYTHONPATH" | export PYTHONPATH="$DEBLOC_ROOT/usr/lib/python3/dist-packages:$PYTHONPATH" | ||||||
| export QT_QPA_PLATFORM_PLUGIN_PATH="$DEBLOC_ROOT/usr/lib/x86_64-linux-gnu/qt5/plugins/platforms" | export QT_QPA_PLATFORM_PLUGIN_PATH="$DEBLOC_ROOT/usr/lib/x86_64-linux-gnu/qt5/plugins/platforms" | ||||||
| 
 | 
 | ||||||
| # Tell if a package exists | # Tell if a package exists | ||||||
|  | @ -61,7 +62,7 @@ function _debloc-locallyInstalled { # package | ||||||
| # Tell if a package is installed system-wide | # Tell if a package is installed system-wide | ||||||
| function _debloc-globallyInstalled { # package | function _debloc-globallyInstalled { # package | ||||||
|     STATUS=$(mktemp) |     STATUS=$(mktemp) | ||||||
|     LANG=C dpkg --status $1 &> $STATUS |     LANG=C dpkg --list $1 &> $STATUS | ||||||
|     if [ $? != 0 ]; then |     if [ $? != 0 ]; then | ||||||
|         rm -f $STATUS > /dev/null |         rm -f $STATUS > /dev/null | ||||||
|         return 0 |         return 0 | ||||||
|  | @ -113,16 +114,14 @@ function _debloc-packageMd5sum { # package | ||||||
| 
 | 
 | ||||||
| # Update symbolics links in $DEBLOC_ROOT/lib | # Update symbolics links in $DEBLOC_ROOT/lib | ||||||
| function _debloc-ldconfig { | function _debloc-ldconfig { | ||||||
|     mkdir -p $DEBLOC_ROOT/lib &> /dev/null |     mkdir -p $DEBLOC_LD &> /dev/null | ||||||
|     rm -f $DEBLOC_ROOT/lib/* &> /dev/null |     rm -f $DEBLOC_LD &> /dev/null | ||||||
|     if [ -e $DEBLOC_ROOT/usr/lib ]; then |     find $DEBLOC_ROOT{/usr,}/lib -type f -name "*.so*" | while read lib; do | ||||||
|         find $DEBLOC_ROOT/usr/lib -type f -name "*.so*" | while read lib; do |         ln --symbolic --force "$lib" "$DEBLOC_LD/$(basename $lib)" | ||||||
|             ln --symbolic --force "$lib" "$DEBLOC_ROOT/lib/$(basename $lib)" |     done &> /dev/null | ||||||
|         done |     find $DEBLOC_ROOT{/usr,}/lib -type l -name "*.so*" | while read link; do | ||||||
|         find $DEBLOC_ROOT/usr/lib -type l -name "*.so*" | while read link; do |         yes | cp --force --no-dereference --preserve=links "$link" "$DEBLOC_LD" &> /dev/null | ||||||
|             yes | cp --force --no-dereference --preserve=links "$link" "$DEBLOC_ROOT/lib/" &> /dev/null |     done &> /dev/null | ||||||
|         done |  | ||||||
|     fi |  | ||||||
| 
 | 
 | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
|  | @ -137,14 +136,14 @@ function _debloc-installDeb { # path | ||||||
|         tar xf $TAR_FILE -C $DEBLOC_ROOT |         tar xf $TAR_FILE -C $DEBLOC_ROOT | ||||||
| 
 | 
 | ||||||
|         # _debloc-ldconfig |         # _debloc-ldconfig | ||||||
|         mkdir -p $DEBLOC_ROOT/lib &> /dev/null |         mkdir -p $DEBLOC_LD &> /dev/null | ||||||
|         tar tf $TAR_FILE | grep '^./usr/lib/' | grep '\.so' | while read file; do |         tar tf $TAR_FILE | grep '^.\(/usr\)\?/lib/' | grep '\.so' | while read file; do | ||||||
|             lib=$(readlink -f $DEBLOC_ROOT/$file) |             lib=$(readlink -f $DEBLOC_ROOT/$file) | ||||||
|             if [ -f $lib ]; then |             if [ -f $lib ]; then | ||||||
|                 ln --symbolic --force "$lib" "$DEBLOC_ROOT/lib/$(basename $file)" |                 ln --symbolic --force "$lib" "$DEBLOC_LD/$(basename $file)" | ||||||
|             fi |             fi | ||||||
|             if [ -h $lib ]; then |             if [ -h $lib ]; then | ||||||
|                 yes | cp --force --no-dereference --preserve=links "$(basename $link)" "$DEBLOC_ROOT/lib/" &> /dev/null |                 yes | cp --force --no-dereference --preserve=links "$(basename $link)" "$DEBLOC_LD/" &> /dev/null | ||||||
|             fi |             fi | ||||||
|         done |         done | ||||||
|     fi |     fi | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue