diff --git a/.vscode/tasks.json b/.vscode/tasks.json index 7fce6af..80af446 100644 --- a/.vscode/tasks.json +++ b/.vscode/tasks.json @@ -8,42 +8,42 @@ "type": "shell", "command": "make", "problemMatcher": [], - "group": { - "kind": "build", - "isDefault": true - } - },{ + "group": "build" + }, + { "label": "Make Build Directory", - "problemMatcher" : [], + "problemMatcher": [], "command": "mkdir", - "args" : [ + "args": [ "-p", "${workspaceFolder}/build" ] - },{ + }, + { "label": "Fetch Upstream Tarball", "group": "build", - "problemMatcher" : [], + "problemMatcher": [], "command": "uscan", - "args" : [ + "args": [ "--force-download", "--destdir", "${workspaceFolder}/build" ], "dependsOn": "Make Build Directory" - },{ + }, + { "label": "Build Debian Package", "group": "build", "problemMatcher": [], "command": "gbp", - "args" : [ + "args": [ "buildpackage", - "--git-debian-branch=main", + "--git-ignore-branch", "-uc", "-us", "--git-tarball-dir=${workspaceFolder}/build", "--git-export-dir=${workspaceFolder}/build" - ], + ] } ] -} \ No newline at end of file +} diff --git a/bin/set-wallpaper b/bin/set-wallpaper index 44e640e..dd463ec 100644 --- a/bin/set-wallpaper +++ b/bin/set-wallpaper @@ -4,21 +4,25 @@ GSETTINGS=/usr/bin/gsettings XFCONF=/usr/bin/xfconf-query # Disable the built in screensaver and show wallpaper -if command -v ${GSETTINGS} &> /dev/null -then - ${GSETTINGS} set org.gnome.desktop.background picture-uri \ - 'file:///usr/share/nsls2/wallpapers/wallpaper.jpg' - ${GSETTINGS} set org.cinnamon.desktop.background picture-uri \ - 'file:///usr/share/nsls2/wallpapers/wallpaper.jpg' +if [ echo "${XDG_CURRENT_DESKTOP}" | grep GNOME ]; then + if [ command -v ${GSETTINGS} &> /dev/null ]; then + echo "Setting Wallpaper for GNOME" + ${GSETTINGS} set org.gnome.desktop.background picture-uri \ + 'file:///usr/share/nsls2/wallpapers/wallpaper.jpg' + ${GSETTINGS} set org.cinnamon.desktop.background picture-uri \ + 'file:///usr/share/nsls2/wallpapers/wallpaper.jpg' + fi fi -if command -v ${XFCONF} &> /dev/null -then - for item in $(${XFCONF} --channel xfce4-desktop --list | grep 'last-image\|image-path') - do - echo ${item} - ${XFCONF} --channel xfce4-desktop \ - --property ${item} \ - --set /usr/share/nsls2/wallpapers/wallpaper.jpg - done +if [ echo "${XDG_CURRENT_DESKTOP}" | grep XFCE ]; then + if [ command -v ${XFCONF} &> /dev/null ]; then + echo "Setting Wallpaper for XFCE" + for item in $(${XFCONF} --channel xfce4-desktop --list | grep 'last-image\|image-path') + do + echo ${item} + ${XFCONF} --channel xfce4-desktop \ + --property ${item} \ + --set /usr/share/nsls2/wallpapers/wallpaper.jpg + done + fi fi