在容器初始化时自动设置 git 用户名和邮箱
This commit is contained in:
4
main.tf
4
main.tf
@@ -73,6 +73,10 @@ EOF
|
|||||||
|
|
||||||
echo "SSH key pair created. Your public key is:"
|
echo "SSH key pair created. Your public key is:"
|
||||||
cat ~/.ssh/git.pub
|
cat ~/.ssh/git.pub
|
||||||
|
|
||||||
|
# 添加 git 全局配置
|
||||||
|
git config set --global user.name "${data.coder_workspace_owner.me.name}"
|
||||||
|
git config set --global user.email "${data.coder_workspace_owner.me.email}"
|
||||||
|
|
||||||
touch ~/.init_done
|
touch ~/.init_done
|
||||||
fi
|
fi
|
||||||
|
|||||||
Reference in New Issue
Block a user