Hi,
I've set up my pi so that I can connect without a password. (id_rsa.pub)
I would like to write a batch script that simply:
ssh pi@10.10.10.73
cd ~/gitRepos/MyRepo
git pull
Any ideas on how to do this?
Note: I have tried this in a .sh file:
ssh pi@10.10.10.73 <<'ENDSSH'
cd ~/gitRepos/MyRepo
git pull
ENDSSH
And here is my output:
Pseudo-terminal will not be allocated because stdin is not a terminal.
Linux rasbpi 3.12.22+ #691 PREEMPT Wed Jun 18 18:29:58 BST 2014 armv6l
The programs included with the Debian GNU/Linux system are free software;
the exact distribution terms for each program are described in the
individual files in /usr/share/doc/*/copyright.
Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent
permitted by applicable law.
fatal: /usr/lib/git-core/git-pull cannot be used without a working tree.
Note: When I log in to the pi and use "git pull" it works fine.