0

I am not able to write git pull command in a file. I have tried running these commands but of no help

git pull --all --dry-run >~/temp1
cat ~/temp1

output is just have a single line "Fetching origin" and rest of the output is dumped on the command line. I have also tried

git pull --all --dry-run |tee -a ~/temp1

Kindly help me how to go about it. Thanks in advance

Bharat Bhagat
  • 381
  • 1
  • 5
  • 14

1 Answers1

1

Try redirecting stdout and stderr to the file, something like.

git pull --all --dry-run > ~/temp1 2>&1
Jetchisel
  • 7,493
  • 2
  • 19
  • 18