exo-open ssh://<computer>

killermoehre killermoehre at gmx.net
Wed Apr 5 18:48:33 CEST 2017


Am 05.04.2017 um 18:25 schrieb Jeff Sadowski:
> for now I wrote a wrapper like so
> 
> #!/bin/bash
> if [ "${1:0:6}" = "ssh://" ];then
> /usr/bin/gnome-open "$@"
> else
> /usr/bin/exo-open-moved "$@"
> fi
> 
> I moved /usr/bin/exo-open to /usr/bin/exo-open-moved
> and linked to my wrapper from /usr/bin/exo-open
> 
> 
> On Tue, Apr 4, 2017 at 4:19 PM, Jeff Sadowski <jeff.sadowski at gmail.com
> <mailto:jeff.sadowski at gmail.com>> wrote:
> 
>     After a while I get a message in a popup:
> 
>     Failed to open "File System".
>     Connection failed.
> 
>     On Tue, Apr 4, 2017 at 1:13 PM, Jeff Sadowski
>     <jeff.sadowski at gmail.com <mailto:jeff.sadowski at gmail.com>> wrote:
> 
>         So most other protocols it looks like I can setup as I want why
>         can't I set ssh or sftp what would be preventing that?
>         I tried with ssi://<computer> and did what I did with ssh
>         replacing the ssi at the end and it launches my ssh with the
>         ssi://<computer> link
> 
>         On Tue, Apr 4, 2017 at 1:09 PM, Jeff Sadowski
>         <jeff.sadowski at gmail.com <mailto:jeff.sadowski at gmail.com>> wrote:
> 
>             I realize you said sftp not scp which when I tried sftp it
>             did nothing like ssh did.
>             When I tried setting it with xdg-mime it still does nothing.
>             Interesting that scp did work. 
> 
>             On Tue, Apr 4, 2017 at 1:00 PM, Jeff Sadowski
>             <jeff.sadowski at gmail.com <mailto:jeff.sadowski at gmail.com>>
>             wrote:
> 
>                 xdg-mime default scp.desktop x-scheme-handler/scp
>                 nano ~/.local/share/applications/scp.desktop
> 
>                 <=============content
>                 [Desktop Entry]
>                 Version=1.0
>                 Type=Application
>                 Exec=bash -c '(URL="%U" HOST="${URL:6}";
>                 $HOME/test_scp.sh $HOST); bash'
>                 Icon=utilities-terminal
>                 StartupNotify=true
>                 Terminal=true
>                 MimeType=x-scheme-handler/ssh
>                 Name=SSH Launcher
>                 Comment=Launch SSH
>                 <===============end content
> 
>                 did work.
> 
>                 On Tue, Apr 4, 2017 at 12:31 PM, Jeff Sadowski
>                 <jeff.sadowski at gmail.com
>                 <mailto:jeff.sadowski at gmail.com>> wrote:
> 
>                     I never added scp with xdg-mime. I did add ssh which
>                     seems to work for gnome-open but not for exo-open.
> 
>                     On Tue, Apr 4, 2017 at 12:28 PM, Jeff Sadowski
>                     <jeff.sadowski at gmail.com
>                     <mailto:jeff.sadowski at gmail.com>> wrote:
> 
>                         Failed to open URI
>                         "scp://jeff-server/home/jeff/testfile".
>                         The specified location is not supported
> 
>                         On Tue, Apr 4, 2017 at 12:18 PM, killermoehre
>                         <killermoehre at gmx.net
>                         <mailto:killermoehre at gmx.net>> wrote:
> 
> 
> 
>                             Am 4. April 2017 19:57:32 MESZ schrieb Jeff
>                             Sadowski <jeff.sadowski at gmail.com
>                             <mailto:jeff.sadowski at gmail.com>>:
>                             >I would like to set exo-open to run a
>                             script of mine in the default
>                             >terminal program.
>                             >
>                             >I have "gnome-open ssh://<computer>" acting
>                             as I like by using:
>                             >
>                             >xdg-mime default ssh.desktop
>                             x-scheme-handler/ssh
>                             >
>                             >and used a text editor to make
>                             ~/.local/share/applications/ssh.desktop
>                             >
>                             >But xdg-open uses exo-open for XFCE4 so I
>                             would like to know how to
>                             >setup
>                             >exo-open to recognize a new protocol like
>                             ssh://<computer>?
>                             >
>                             >Is this possible?
>                             >
>                             >The purpose is to use this in
>                             google-chrome. Google-chrome doesn't give
>                             >an
>                             >option to send more arguments that I can see.
>                             >
>                             >I see people talking about adding options
>                             to the command line but as I
>                             >said
>                             >that will not work as other programs will
>                             not send those to xdg-open.
> 
>                             Hi Jeff,
> 
>                             does it work if you just use »exo-open
>                             sftp://host/path/to/file«?

Hi,

»xdg-open ssh://host/path/to/file« is working very well for me on my
Arch Linux without any need for wrappers. But if you want to be a little
bit more purist, use first »gvfs-mount ssh://host/path/to/file« and than
»gvfs-open ssh://host/path/to/file«, because exo-open (called by
xdg-open if this script detects Xfce) is basically falling back to gvfs
(first mounting, than opening) if available.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 927 bytes
Desc: OpenPGP digital signature
URL: <https://mail.xfce.org/pipermail/xfce/attachments/20170405/7b3c1384/attachment.sig>


More information about the Xfce mailing list