I'd like to automate the process of syncing a local
~/bin folder to a remote host, and adding that folder to my remote shell's path. I've got the syncing part done, but am not sure how to automate adding the folder to my remote shell's
This way I could always work on my shell scripts on my local machine, and if I have to connect to a new machine and start working on it, I could just run a local script to sync my ~/bin folder to the remote machine, and then run scripts on the remote host easily all the time.
So how can I ensure that my
~/bin path is added to the
$PATH of the remote host, so the next time I login, the
$PATH is set correctly?
I'd like this to be done automatically from my shell script.
EDIT: I'd prefer not to sync a
.bashrc, but append to an existing file if need be by adding something to the end using a shell script.