09-torsocks-apps 688 B

1234567891011121314151617181920212223
  1. #!/bin/sh
  2. set -e
  3. echo "Wrapping some applications with torsocks"
  4. APPS="gobby-0.5 liferea openpgp-applet seahorse"
  5. DBUS_SERVICES="org.gnome.seahorse.Application org.fedoraproject.Config.Printing"
  6. for app in $APPS; do
  7. sed -i'' --regexp-extended 's,^Exec=(.*),Exec=torsocks \1,' \
  8. "/usr/share/applications/${app}.desktop"
  9. done
  10. for dbus_service in $DBUS_SERVICES; do
  11. sed -i'' --regexp-extended 's,^Exec=(.*),Exec=/usr/bin/torsocks \1,' \
  12. "/usr/share/dbus-1/services/${dbus_service}.service"
  13. done
  14. # Redirect to existing wrapper
  15. sed -i'' --regexp-extended 's,^Exec=/usr/bin/totem$,Exec=/usr/local/bin/totem,' \
  16. "/usr/share/dbus-1/services/org.gnome.Totem.service"