git——》删除文件夹

版权声明:本文为博主原创文章,无需授权即可转载,甚至无需保留以上版权声明,转载时请务必注明作者。
https://blog.csdn.net/weixin_43453386/article/details/84585596

git——》删除文件夹

  • 一、分步骤操作
    • 1、找到文件夹目录
    • 2、删除文件夹
    • 3、commit到本地
    • 4、push到远程
  • 二、整体操作

一、分步骤操作 1、找到文件夹目录 cd java\com\ejudata\platform
2、删除文件夹 git rm -rf 文件夹名
3、commit到本地 git commit -m 'delete dir'
4、push到远程 【git——》删除文件夹】git push
二、整体操作
E:\eju_IdeaProjects\house-platform\web-data\src\main>cd java\com\ejudata\platform E:\eju_IdeaProjects\house-platform\web-data\src\main\java\com\ejudata\platform>git rm -rf test rm 'web-data/src/main/java/com/ejudata/platform/test/Test.java'E:\eju_IdeaProjects\house-platform\web-data\src\main\java\com\ejudata\platform>git add -A E:\eju_IdeaProjects\house-platform\web-data\src\main\java\com\ejudata\platform>git commit -m 'delete' [v1.2 eaed2cf] 'delete' 1 file changed, 4 deletions(-) delete mode 100644 web-data/src/main/java/com/ejudata/platform/test/Test.javaE:\eju_IdeaProjects\house-platform\web-data\src\main\java\com\ejudata\platform>git push Username for 'http://git.eju-inc.com': 600387 Password for 'http://600387@git.eju-inc.com': Counting objects: 9, done. Delta compression using up to 4 threads. Compressing objects: 100% (6/6), done. Writing objects: 100% (9/9), 647 bytes | 161.00 KiB/s, done. Total 9 (delta 2), reused 0 (delta 0) remote: remote: To create a merge request for v1.2, visit: remote:http://git.eju-inc.com/eju-data/SecondHandHouse-Project/house-platform/merge_requests/new?merge_request%5Bsource_branch%5D=v1.2 remote: To http://git.eju-inc.com/eju-data/SecondHandHouse-Project/house-platform.git c728782..eaed2cfv1.2 -> v1.2

    推荐阅读