--- Hide.cpp ---
#include <process.h>
#include <stdio.h>

int main ( int argc, char **argv) {
        if ( argc < 2 ) {
                printf("usage: %s [program] [arg1] [arg2]\n", argv[0]);
                return -1;
        };
        if ( _spawnvp(_P_DETACH,argv[1], argv+1) ) {
                perror("_spawnvp");
                exit(1);
        };
        return 0;
};
--- Hide.cpp ---

--- sshagent ---
ssh-agent > ~/.ssh-agent
--- sshagent ---

--- .bashrc: ---
if tty -s ; then
  . ~/.ssh-agent
fi
--- .bashrc ---


to compile:  CXX_FLAGS=-mno-cygwin make Hide

to run ssh-agent out of sight and out of mind:
bash$ ./Hide bash sshagent
bash$ exec bash


--
Want to unsubscribe from this list?
Check out: http://cygwin.com/ml/#unsubscribe-simple

Reply via email to