Hi!
I'm somewhat new to Linux. I have only been using it for a couple of weeks, and I have slowly been solving problems and tweaking my installation. I am currently on Debian 12, using lightdm with slick-greeter.
Currently I have been trying to set a wallpaper on startup, which would have be easy if I had kept xfce. However I switched to dwm. I understand how to apply a wallpaper to my desktop background, but I have had much difficulty having it persist on reboot. I first tried to place a pywal or feh command into my .xinitrc file that would apply a wallpaper, however this did not work. I think that this is because I do not start dwm through xinitrc, but through /usr/share/xsessions by using a .desktop file for it, but i'm not sure. I also tried bash scripting to run the command, crontab, variety, changing lightdm's config file, as well as using the rc.local script to start the command I need to run at boot in order to apply the wallpaper. These attempts did not work either, most likely because I did something wrong.
I also messed around with the dwm autostart patch, but I honestly don't know how to configure it.
So as of right now i'm kinda at a loss. I've been trying to troubleshoot this for a week straight with no luck. Would somebody have an idea as to what I should do to apply a wallpaper on startup? Thanks for your time.
Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230
[Solved] Setting a wallpaper in dwm on startup[O/S]
-
- Posts: 2
- Joined: 2024-04-17 05:59
[Solved] Setting a wallpaper in dwm on startup[O/S]
Last edited by TheInquisitor on 2024-04-17 21:31, edited 1 time in total.
- None1975
- df -h | participant
- Posts: 1421
- Joined: 2015-11-29 18:23
- Location: Russia, Kaliningrad
- Has thanked: 47 times
- Been thanked: 68 times
Re: [O/S] Setting a wallpaper in dwm on startup[O/S]
Hello.
Create .xsessionrc file with these contents:
make this file executable:
Logout and login again.
P.S.
This way, using this file, you can specify the programs you want to start when you start a graphics session.
Keep in mind that some apps need to run in the background. Therefore, you need to add & to their name
Good luck.
You don't need it at allI also messed around with the dwm autostart patch, but I honestly don't know how to configure it.
Create .xsessionrc file with these contents:
Code: Select all
#!/bin/bash
~/.fehbg
Code: Select all
chmod +x ~/.xsessionrc
P.S.
This way, using this file, you can specify the programs you want to start when you start a graphics session.
Keep in mind that some apps need to run in the background. Therefore, you need to add & to their name
Good luck.
OS: Debian 12.4 Bookworm / DE: Enlightenment
Debian Wiki | DontBreakDebian, My config files on github
Debian Wiki | DontBreakDebian, My config files on github
-
- Posts: 2
- Joined: 2024-04-17 05:59
Re: [O/S] Setting a wallpaper in dwm on startup[O/S]
Thanks that worked like a charm!
Ill mark the post as solved. However I have a quick newbie question. When I was writing the command I wanted into the ~/.xsessionrc file I first tried using pywal using "wal -R". This did not work, so I then looked closer at what you had suggested to do, and saw that you provided a file path for the command. I tried that instead with pywal and bam, worked instantly. I would like to understand why you have to specify a file path for the command, if you would care to explain.
Again thanks for the help
Ill mark the post as solved. However I have a quick newbie question. When I was writing the command I wanted into the ~/.xsessionrc file I first tried using pywal using "wal -R". This did not work, so I then looked closer at what you had suggested to do, and saw that you provided a file path for the command. I tried that instead with pywal and bam, worked instantly. I would like to understand why you have to specify a file path for the command, if you would care to explain.
Again thanks for the help
- None1975
- df -h | participant
- Posts: 1421
- Joined: 2015-11-29 18:23
- Location: Russia, Kaliningrad
- Has thanked: 47 times
- Been thanked: 68 times
Re: [O/S] Setting a wallpaper in dwm on startup[O/S]
Path name really means the full path to that file or folder from the filesystem's / directory. For example, the full path to your script is:TheInquisitor wrote: ↑2024-04-17 21:30 Thanks that worked like a charm!
I would like to understand why you have to specify a file path for the command, if you would care to explain.
Code: Select all
/home/your_username/my_script
The root directory
Code: Select all
/
More info here
Good luck.
OS: Debian 12.4 Bookworm / DE: Enlightenment
Debian Wiki | DontBreakDebian, My config files on github
Debian Wiki | DontBreakDebian, My config files on github