search

Home  >  Q&A  >  body text

本地直接删除文件后,git到远程仓库,为什么不会同步删除对应文件

本地直接删除文件后,git到远程仓库,为什么不会同步删除对应文件

我想大声告诉你我想大声告诉你2811 days ago704

reply all(4)I'll reply

  • 滿天的星座

    滿天的星座2017-05-02 09:24:42

    Resolved

    git add -A
    

    It can stage all files, and it was used before

    git add .
    

    Only new files and modified files can be staged, no deleted files

    reply
    0
  • 黄舟

    黄舟2017-05-02 09:24:42

    When you git upload, take a look at yourself

    There should be some unuploaded marks

    If you want to upload delete (upload all)
    git add --all

    Upload and delete if you want
    Baidu by yourself

    reply
    0
  • 曾经蜡笔没有小新

    曾经蜡笔没有小新2017-05-02 09:24:42

    Commit the changes before pushing

    reply
    0
  • 高洛峰

    高洛峰2017-05-02 09:24:42

    I feel like you didn’t commit into the repository
    It is recommended to use the command git add -A然后使用命令git commit -m "del" 再然后要使用 git push in the project root directory to push to the remote server

    It is recommended to use the git status command again after each add to check whether it has been staged

    reply
    0
  • Cancelreply