when I use template in local folder, it works, but I want to use template in my github like npm install git files as npm install \
react-native init templateTest --version 0.59.10 --template git://github.com/xxx/react-native-template.git
You're using legacy init, which we don't maintain anymore. Please use the new one:
npx react-native init templateTest --template git://github.com/xxx/react-native-template.git
Notice npx and using either version or template, not both. Also, template needs to conform to a new, simpler format: https://github.com/react-native-community/cli/blob/master/docs/init.md#creating-custom-template
In case npx react-native gives the same results, you should be able to fix it by running npx [email protected] or npx @react-native-community/cli instead.