Skip to content

Instantly share code, notes, and snippets.

@nwhobart
Last active Dec 23, 2016
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

derekbassett commented Dec 23, 2016

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