#!/usr/bin/env bash

# setup polybar
sed -i '/base/{n;N;N;d}' $HOME/.config/polybar/config
sed -i "/base/ a\
include-file = ${HOME}/.config/polybar/master.conf" $HOME/.config/polybar/config
sed -i "/base/ a\
include-file = ${HOME}/.config/polybar/modules.conf" $HOME/.config/polybar/config

# set firefox homepage
sed -i "s/liveuser/${USER}/g" $HOME/.mozilla/firefox/archlabs.default/prefs.js
sed -i "s/liveuser/${USER}/g" $HOME/.mozilla/firefox/archlabs.default/sessionstore.js

# setup gorice
sed -i "s/liveuser/${USER}/g" $HOME/.gorice/templates/i3/data.json

# set bookmarks in thunar
sed -i "s/liveuser/${USER}/g" $HOME/.config/gtk-3.0/bookmarks

# remove itself
rm -f $HOME/.config/setup
