git post-receive read oldrev newrev ref : bad variable name

126 Views Asked by At
#!/bin/bash
read oldrev newrev ref
echo "$ref"

return

remote: : not found
remote: : not found
remote: : not found
remote: : bad variable name

nothing work even when put "export PATH=$PATH:/bin/...etc"

1

There are 1 best solutions below

0
On
export LANG=en_US.UTF-8

seems to do the trick.

However, it seemed to me that it was not necessary because Debian buster had utf8 as a base. Apparently not. Git should not take basic bash parameters