vado-0.0.11: Runs commands on remote machines using ssh

Safe HaskellSafe



Lets you quickly run ssh on a machine that you have an sshfs connection to. It works out the username, host and the directory on the host based on the current directory and the output of mount



data MountPoint Source #

Remote file system mount point




parseMountPoint Source #


:: String

line of output fromt he mount command

-> Maybe MountPoint 

Parses a line looking for a remote mount point

getMountPoint Source #


:: FilePath

Local directory to find the mount point

-> IO (Either MountPoint String)

Details of the mount point or an error string

Run mount and look up the mount point relating to the directory in the output

readSettings :: IO [MountSettings] Source #

Read a list of predefined mount points from the ~/.vadosettings files

defMountSettings :: IO MountSettings Source #

Default mount settings for vagrant

vado Source #


:: MountPoint

Mount point found using getMountPoint

-> [MountSettings]

SSH settings from the '.vadosettings' files

-> FilePath

Local directory you want the command to run in. Normally this will be the same directory you passed to getMountPoint. The vado will run the command in the remote directory that maps to this one.

-> [String]

Options to pass to ssh. If the mount point is 'vagrant@' then the most common vagrant connection options ('-p2222' and '-i~/.vagrant.d/insecure_private_key') are included automatically

-> FilePath

Command to run

-> [String]

Arguments to pass to the command

-> IO [String]

Full list of arguments that should be passed to ssh

Get a list of arguments to pass to ssh to run command on a remote machine in the directory that is mounted locally

vamount Source #


:: MountSettings

Mount settings to use

-> FilePath

Remote directory to mount

-> FilePath

Local directory (where to mount)

-> [String]

Other options to pass to sshfs

-> [String]

Resulting list of arguments

Get a list of arguments to pass to sshfs to mount a remote filesystem in the given directory