As the title, remote login to the Linux server, execute
git clone https://git.oschina.net/chenjianlong/JRoll2.git
//error
(gnome-ssh-askpass:609): Gtk-WARNING **: cannot open display:
Solution 1:
unset SSH_ASKPASS
Then enter the password
The reason is that the HTTPS protocol is used, and the password is required for each submission. If the GIT command is executed automatically by shell, the script will be interrupted and cannot be executed
Solution 2: Using SSH
Method reference for generating SSH: git on server – generate SSH public key
git clone [email protected]:chenjianlong/JRoll2.git
You only need to confirm the SSH link once