mirror of
https://gitea.blesmrt.net/mikaela/shell-things.git
synced 2024-11-12 19:39:23 +01:00
darkman: attempt to decrease amount of repeating myself
This commit is contained in:
parent
80119c9059
commit
d41e225bf0
9
local/share/dark-mode.d/00-do-not-repeat-yourself.sh
Normal file
9
local/share/dark-mode.d/00-do-not-repeat-yourself.sh
Normal file
@ -0,0 +1,9 @@
|
|||||||
|
if ! hash lsb_release 2> /dev/null; then
|
||||||
|
ERRORMESSAGE="lsb_release was not found, the wallpaper scripts cannot figure out the distribution"
|
||||||
|
echo $ERRORMESSAGE
|
||||||
|
#notify-send $ERRORMESSAGE
|
||||||
|
exit 0
|
||||||
|
fi
|
||||||
|
|
||||||
|
export DISTROID=$(lsb_release -si)
|
||||||
|
export DISTROREL=$(lsb_release -sr)
|
@ -1,14 +1,6 @@
|
|||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
if ! hash lsb_release 2> /dev/null; then
|
. 00-do-not-repeat-yourself.sh
|
||||||
ERRORMESSAGE="lsb_release was not found, the wallpaper scripts cannot figure out the distribution"
|
|
||||||
echo $ERRORMESSAGE
|
|
||||||
notify-send $ERRORMESSAGE
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
|
|
||||||
export DISTROID=$(lsb_release -si)
|
|
||||||
export DISTROREL=$(lsb_release -sr)
|
|
||||||
|
|
||||||
if [ -f ~/.wallpaper.dark ]; then
|
if [ -f ~/.wallpaper.dark ]; then
|
||||||
export WALLPAPER_PATH="$HOME/.wallpaper.dark"
|
export WALLPAPER_PATH="$HOME/.wallpaper.dark"
|
||||||
|
1
local/share/light-mode.d/.gitignore
vendored
Normal file
1
local/share/light-mode.d/.gitignore
vendored
Normal file
@ -0,0 +1 @@
|
|||||||
|
00-do-not-repeat-yourself.sh
|
1
local/share/light-mode.d/00-do-not-repeat-yourself.sh
Symbolic link
1
local/share/light-mode.d/00-do-not-repeat-yourself.sh
Symbolic link
@ -0,0 +1 @@
|
|||||||
|
../dark-mode.d/00-do-not-repeat-yourself.sh
|
@ -1,14 +1,6 @@
|
|||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
if ! hash lsb_release 2> /dev/null; then
|
. 00-do-not-repeat-yourself.sh
|
||||||
ERRORMESSAGE="lsb_release was not found, the wallpaper scripts cannot figure out the distribution"
|
|
||||||
echo $ERRORMESSAGE
|
|
||||||
notify-send $ERRORMESSAGE
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
|
|
||||||
export DISTROID=$(lsb_release -si)
|
|
||||||
export DISTROREL=$(lsb_release -sr)
|
|
||||||
|
|
||||||
if [ -f ~/.wallpaper.light ]; then
|
if [ -f ~/.wallpaper.light ]; then
|
||||||
export WALLPAPER_PATH="$HOME/.wallpaper.light"
|
export WALLPAPER_PATH="$HOME/.wallpaper.light"
|
||||||
|
Loading…
Reference in New Issue
Block a user