Skip to content

Instantly share code, notes, and snippets.

@nwhobart
Last active December 23, 2016 15:46
Embed
What would you like to do?
#!/usr/bin/env bash
ssh -t user@server.com 'df -h'
^^^^^^ does not work ^^^^^^^
ssh: command not found
------------------------------------------
#!/usr/bin/env bash
/usr/bin/ssh -t user@server.com 'df -h'
^^^^works fine^^^^^^
WHY THE FUCK DO I NEED TO SPECIFY A PATH FOR SSH?
"/usr/bin" is in my $PATH for `bash`
@derekbassett
Copy link

Try an 'echo $PATH' in your script to verify that.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment