Added menu shortcut.

This commit is contained in:
Peter Green 2023-01-08 20:45:10 +00:00
parent 8365bfc02a
commit 783f1adc7b
2 changed files with 15 additions and 2 deletions

7
Backup.desktop Normal file
View File

@ -0,0 +1,7 @@
[Desktop Entry]
Name=Backup Home
Exec=
Comment=A script to back up your home dir
Terminal=true
Icon=
Type=Application

View File

@ -18,7 +18,12 @@ if [ -d "$HOME"/bin ];
else mkdir "$HOME"/bin
fi
~ Make the root dir...
# Edit the menu entry file...
sed -i "s|Exec=|Exec=$HOME/bin/backup_home|" "$pwd"/Backup.desktop
sed -i "s|Icon=|Icon=$HOME/bin/backup_home|" "$pwd"/Backup.desktop
# Make the root dir...
mkdir "$HOME"/bin/backup_home
# Copy files over to ~/bin
@ -27,8 +32,9 @@ cp "$pwd"/Backup.sh "$HOME"/bin/backup_home
cp "$pwd"/Backup.svg "$HOME"/bin/backup_home
cp "$pwd"/LICENSE "$HOME"/bin/backup_home
cp "$pwd"/README.md "$HOME"/bin/backup_home
cp "$pwd"/Backup.desktop "$HOME"/.local/share/applications
# let the user know we have finished...
# Let the user know we have finished...
echo "All done! Press 'Enter' to close this window..."
read -r