Guest User

install_playkey.sh

a guest
Dec 4th, 2015
1,017
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 1.00 KB | None | 0 0
  1. #/bin/bash
  2.  
  3. # First, create a .desktop description file:
  4. cat << EOF > playkey.desktop
  5. [Desktop Entry]
  6. Encoding=UTF-8
  7. Version=1.0
  8. Type=Application
  9. Terminal=false
  10. Icon=Playkey.svg
  11. Categories=Application;Games;
  12. MimeType=x-scheme-handler/playkey;
  13. Name=Playkey
  14. Comment=Playkey cloud gaming service
  15. Name[en_US]=Playkey
  16. Comment[en_US]=Playkey cloud gaming service
  17. Name[en_US.utf8]=Playkey
  18. Comment[en_US.utf8]=Playkey cloud gaming service
  19. StartupNotify=true
  20. EOF
  21.  
  22. # Then add command line to run playkey client:
  23. echo "Exec=\"${HOME}/.wine/drive_c/Program Files (x86)/Playkey/Playkey.exe\" %u" >> playkey.desktop
  24. chmod +x playkey.desktop
  25.  
  26.  
  27. # Now install it to user's home directory so xdg-mime and xdg-open can find it:
  28. xdg-desktop-menu install --novendor --mode user playkey.desktop
  29.  
  30. # Now set url scheme handler:
  31. xdg-mime default playkey.desktop x-scheme-handler/playkey
  32. xdg-settings set default-url-scheme-handler playkey playkey.desktop
  33.  
  34. # Update desktop menu cache
  35. update-desktop-database
Advertisement
Add Comment
Please, Sign In to add comment