且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

无法使用git add暂存文件夹以进行提交.或git add -u

更新时间:2022-02-08 04:28:05

它( bsg-services )是 此灰色git图标是什么?")

您需要:

  • 首先进入该文件夹(并从该子仓库中推送)来添加/提交,
    ( bsg-services 内部的git状态将告诉您更多信息)
  • 然后返回父仓库(您所在的位置),添加,提交和推送.
    您将在 bsg-services 内部完成的提交将修改 gitlink条目在父仓库的索引中.
  • add/commit by going in that folder first (and push from that sub repo),
    (a git status inside bsg-services will tell you more)
  • then go back to the parent repo (where you are), add, commit and push.
    The commit you will have done inside bsg-services will have modified the gitlink entry in the index of your parent repo.

因此您需要两次下推:

  • 从子模块存储库到其上游存储库的一个( git remote -v 应该向您显示)
  • 来自父仓库的一个,以便记录存储该子模块新状态的新gitlink SHA1.