10 lines
377 B
Bash
Executable File
10 lines
377 B
Bash
Executable File
export BG_PATH=~/background
|
|
cd $BG_PATH
|
|
FILENAME=$(basename $(ls *.jpg | sort -R | head -n 1) .jpg)
|
|
SUB="s/^primary = #[a-z0-9]*/primary = #${FILENAME}/"
|
|
echo $FILENAME > color
|
|
sed -i "$SUB" ~/.config/polybar/config
|
|
SUB="s/^client.focused .*/client.focused #${FILENAME} #${FILENAME} #${FILENAME} #${FILENAME} #${FILENAME}/"
|
|
sed -i "$SUB" ~/.config/i3/config
|
|
${0%/*}/refresh.sh
|