I'm trying to learn Linux by creating a script to customize my user... install apps, update them, change the background, favorite apps, and some settings. I ran into a problem and I can't find a solution.
If I run the command
gsettings set org.gnome.shell favorite-apps "['chromium_chromium.desktop', 'whatsdesk_whatsdesk.desktop', 'messengerport_messengerport.desktop', 'enpass.desktop', 'steam.desktop', 'discord_discord.desktop', 'vlc_vlc.desktop', 'org.gnome.Terminal.desktop']"
from the terminal, everything works as expected, but if I put the same command into a script. it doesn't do anything
Can anyone please help me?
EDIT:
For anyone asking..my script is a mess of Linux commands... but i will paste it here
#!/bin/sh
add-apt-repository "deb https://apt.enpass.io/ stable main"
wget -O - https://apt.enpass.io/keys/enpass-linux.key | apt-key add -
sudo apt-get update && sudo apt-get upgrade -y
sudo apt-get dist-upgrade -y
sudo apt install steam-installer enpass openssh-server -y
sudo snap install whatsdesk discord messengerport libreoffice chromium vlc meteo
gsettings set org.gnome.shell favorite-apps "['chromium_chromium.desktop', 'whatsdesk_whatsdesk.desktop', 'messengerport_messengerport.desktop', 'enpass.desktop', 'steam.desktop', 'discord_discord.desktop', 'vlc_vlc.desktop', 'org.gnome.Terminal.desktop']"
sudo apt-get dist-upgrade -y
sudo snap refresh
sudo apt autoremove -y
sudo apt-get autoclean -y