我是git和github的新手,并且想知道如何在没有用户名和密码的情况下git push login-credentials.php
。
假设本地存储库中只有两个文件,index.php
将include ("login-redentials.php");
:
index.php
login-credentials.php
使用git push origin master
时,两个文件都将被推送到github。在这种情况下,username和PASSWORD将被发布。
在使用login-credentials.php
之前,从git push
删除登录凭据的最佳方法是什么? -我在git文档中找不到此用例的最佳实践。