Skip to content

Commit

Permalink
Fixed pop os bug
Browse files Browse the repository at this point in the history
  • Loading branch information
amalthomas-exe committed Jun 14, 2022
1 parent bae7c42 commit 9fe1950
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion main.py
Original file line number Diff line number Diff line change
Expand Up @@ -60,10 +60,16 @@ def setDEWallpaper(de,style):
print("Inside",de)
os.system(f"pcmanfm --set-wallpaper=\"usr/share/linuxDynamicWallpapers/images/{style}/{datetime.datetime.now().hour}"+f"{type}\"")

elif de in ["PANTHEON","Pantheon","pantheon","GNOME","Gnome","gnome","Gnome-xorg","gnome-xorg","UBUNTU","Ubuntu","ubuntu","DEEPIN","Deepin","deepin","POP","Pop","pop"]: #Set Wallpaper for Ubuntu, Pop, Pantheon DE
elif de in ["PANTHEON","Pantheon","pantheon","GNOME","Gnome","gnome","Gnome-xorg","gnome-xorg","UBUNTU","Ubuntu","ubuntu","DEEPIN","Deepin","deepin"]: #Set Wallpaper for Ubuntu, Pop, Pantheon DE
print("Inside",de)
os.system(f"gsettings set org.gnome.desktop.background picture-uri file:///usr/share/linuxDynamicWallpapers/images/{style}/{datetime.datetime.now().hour}"+f"{type}")

elif de in ["POP","Pop","pop"]:
print("Inside",de)
if subprocess.getoutput("gsettings get org.gnome.desktop.interface gtk-theme")=="'Pop-dark'":
os.system(f"gsettings set org.gnome.desktop.background picture-uri-dark file:///usr/share/linuxDynamicWallpapers/images/{style}/{datetime.datetime.now().hour}"+f"{type}")
else:
os.system(f"gsettings set org.gnome.desktop.background picture-uri file:///usr/share/linuxDynamicWallpapers/images/{style}/{datetime.datetime.now().hour}"+f"{type}")
else:
print("Inside",de)
os.system(f"feh --bg-fill usr/share/linuxDynamicWallpapers/images/{style}/{datetime.datetime.now().hour}"+f"{type}")
Expand Down

0 comments on commit 9fe1950

Please sign in to comment.