如何将本地的项目加入git管理?
迷茫
迷茫 2017-05-02 09:30:41
0
3
551

1、我在本地已经有一个项目。
2、开发到一半的时候我想用git来管理这个项目。
3、然后我在github上新建了一个项目
4、那么我如何把本地的项目同新建的git关联起来?
我现在知道的办法是使用git clone下载空项目,然后把之前的项目拷过去,git add 然后 commit push

问题是:我并不想移动或者改原有项目的文件名
PS:我现在使用的环境是CentOS 7

先谢谢回答者~

迷茫
迷茫

业精于勤,荒于嬉;行成于思,毁于随。

reply all(3)
给我你的怀抱
  1. git init

  2. git add .

  3. git commit -m “init”

  4. git remote add origin your github warehouse address

  5. git push

大家讲道理

Execute git init in the directory where your original project is located to create a git project and then synchronize it to the remote server

phpcn_u1582

Create an empty resource library on github,
Build a git environment locally, and submit it to the address of your resource library.
More Baidu, there are many resources
Attachment:
http://www.linuxidc.com/Linux/ 2015-08/121007.htm

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!