Created
July 13, 2023 23:46
-
-
Save nick3499/4bf53b6f549aab4f848301fe51ad5e89 to your computer and use it in GitHub Desktop.
Desktop Launcher
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# Create Chromium URL-as-app launcher given name of video and URL | |
# Example: | |
# $ sh launcher-gen.sh 'Dark Drum and Bass - VOL 2' https://www.youtube.com/watch?v=55kZd_JDrfI | |
NAME="$1" | |
URL=$2 | |
echo '[Desktop Entry]\nVersion=1.0\nType=Application' > /home/$USER/Desktop/$NAME.desktop | |
echo "Name=$NAME" >> /home/$USER/Desktop/$NAME.desktop | |
echo 'Comment=' >> /home/$USER/Desktop/$NAME.desktop | |
echo "Exec=chromium $URL" >> /home/$USER/Desktop/$NAME.desktop | |
echo 'Icon=/usr/share/icons/Flat-Remix-Blue-Dark/mimetypes/scalable/application-audio.svg' >> /home/$USER/Desktop/$NAME.desktop | |
echo 'Path=\nTerminal=false\nStartupNotify=false' >> /home/$USER/Desktop/$NAME.desktop |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Original intention was to create desktop launchers for various music videos; to launch
chromium
and pass it a preset URL.$NAME
(argv[1]) stores the music video name$URL
(argv[2]) stores the video URLIcon=
could be left emptyComment=
could be left empty