I tried to create an auto start script but it doesn’t work. Here’s what I have and I’ve added the script to the login scripts section under autostart in System Settings and checked the box for an executable & also gave it permissions to read, write, and execute (thru chmod). I put the script in my home directory (not sure if that matters or not) and here’s what I have in it (file name: autostart.sh)
Unfortunately doesn’t work. I read something about the autostart.sh.desktop file being the issue but everything in there seems correct so I don’t know either.
Check (and perhaps then configure and extend) your $PATH variable
echo $PATH
include ~/.local/bin in it
and put your script there - instead of into ~/.config
and make the script executable
and modify it by just calling it by it’s (unique) name - not via: bash ~/.config/polybar/launch.sh --forest
more like: launch.sh --forest
(if that name is unique - if no other program in the $PATH has got that same name)
#!/bin/bash
is already enough
there should be no need to then use: bash ~/.config/polybar/launch.sh --forest
inside the script
that is already called as a bash script
The name of the script (no path to it) should be enough.
Sorry I’m new to Linux/Manjaro, to add a directory to $PATH would I go into my .bashrc file and then add the following line of code to the end of the file?
export PATH="~/.local/bin"
And then I would move my autostart.sh file there and re-add it under System Settings? Would I also need to edit the autostart.sh.desktop file to the new directory or will it do it automatically?