#!/bin/bash
# /usr/share/xsessions/
xscreensaver -nosplash &
#cat ~/.config/google-chrome/Local\ State | perl -pe "s/\"bottom.*/\"bottom\": $(xrandr | grep \* | cut -d' ' -f4 | cut -d'x' -f2),/" > ~/.config/chromium/Local\ State
#cat ~/.config/google-chrome/Local\ State | perl -pe "s/\"right.*/\"right\": $(xrandr | grep \* | cut -d' ' -f4 | cut -d'x' -f1),/" > ~/.config/chromium/Local\ State
#sleep 5s

Xaxis=$(xrandr --current | grep '*' | uniq | awk '{print $1}' | cut -d 'x' -f1)

Yaxis=$(xrandr --current | grep '*' | uniq | awk '{print $1}' | cut -d 'x' -f2)

while true; do google-chrome /home/middle/guardian-kiosk-script/script.html --window-size=$Xaxis,$Yaxis --start-maximized --start-fullscreen --kiosk --window-position=0,0; sleep 2s; done

