mirror of
https://github.com/davatorium/rofi.git
synced 2025-07-31 21:59:25 -04:00
parent
cac2eb1a7f
commit
274f2297aa
1 changed files with 7 additions and 2 deletions
|
@ -178,12 +178,17 @@ function set_theme()
|
||||||
${SED} -i "/@import.*/d" "${get_link}"
|
${SED} -i "/@import.*/d" "${get_link}"
|
||||||
echo "@import \"${1}\"" >> "${get_link}"
|
echo "@import \"${1}\"" >> "${get_link}"
|
||||||
else
|
else
|
||||||
if [ -f "${CDIR}/config" ]
|
if [ ! -e "${CDIR}/config" ]
|
||||||
then
|
then
|
||||||
|
# No file.
|
||||||
|
echo "rofi.theme: ${1}" >> "${CDIR}/config"
|
||||||
|
elif [ -f "${CDIR}/config" ]
|
||||||
|
then
|
||||||
|
# Regular file
|
||||||
get_link=$(readlink -f "${CDIR}/config")
|
get_link=$(readlink -f "${CDIR}/config")
|
||||||
${SED} -i "/rofi\.theme: .*\.rasi$/d" "${get_link}"
|
${SED} -i "/rofi\.theme: .*\.rasi$/d" "${get_link}"
|
||||||
|
echo "rofi.theme: ${1}" >> "${get_link}"
|
||||||
fi
|
fi
|
||||||
echo "rofi.theme: ${1}" >> "${get_link}"
|
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue