parent
5d4cc9005a
commit
2fbff4f57c
@ -0,0 +1,22 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
DATA_DIR="$HOME/.config/chromium/Twitch"
|
||||||
|
CHANNEL="ianmethyst"
|
||||||
|
|
||||||
|
WINDOW_WIDTH="400"
|
||||||
|
WINDOW_HEIGHT="600"
|
||||||
|
WINDOW_GEOMETRY="$WINDOW_WIDTH,$WINDOW_HEIGHT"
|
||||||
|
|
||||||
|
RESOLUTION=$(xrandr |awk '$0 ~ "*" {print $1}')
|
||||||
|
SCREEN_WIDTH=$(echo $RESOLUTION | cut -d "x" -f 1)
|
||||||
|
SCREEN_HEIGHT=$(echo $RESOLUTION | cut -d "x" -f 2)
|
||||||
|
WINDOW_X=$(($SCREEN_WIDTH / 2 - WINDOW_WIDTH / 2))
|
||||||
|
WINDOW_Y=$(($SCREEN_HEIGHT / 2 - WINDOW_HEIGHT / 2))
|
||||||
|
WINDOW_POSITION="$WINDOW_X,$WINDOW_Y"
|
||||||
|
|
||||||
|
chromium \
|
||||||
|
--user-data-dir="$DATA_DIR" \
|
||||||
|
--window-position="$WINDOW_POSITION" \
|
||||||
|
--window-size="$WINDOW_GEOMETRY" \
|
||||||
|
--app="https://www.twitch.tv/popout/$CHANNEL/chat" \
|
||||||
|
|
Loading…
Reference in new issue