此文章仅自己可见(bushi)
第一步,打开gitee,新建仓库:仓库名称要和你的python项目名称一致,例如我的python项目名称是 python_code_project

所以我的仓库名也是 python_code_project ,剩下的仓库介绍和初始化仓库自己写一写填一填就行了,我的是这样的:

完事儿后进行下一步。
下一步:在自己的仓库中找到刚刚创建的仓库(我找的是其他的,都差球不多):

复制仓库的https地址,然后随便找个文件夹,在里面打开控制台(用cmd也行,用Git bash也行),用git来clone一下:(在此之前需要在电脑上安装一下Git)

克隆完后,会出现一个文件夹,点进去,然后把里面这三个配置文件全都拷贝到我们本地python项目同名下的文件夹中
 然后在我们本地python项目文件夹中打开控制台,来一个git三连暴走:
- git add .
- git commit -m "this is new code"
- git push
或者
以添加dist文件夹为例 git add less/dist git commit -m “less test” -a # 命令是提交所有文件 git commit -m “somefile” somefile.txt # 这个是提交某个文件夹的命令 git push
完事儿
之后在我们持续的代码提交中,可以只使用git commit 和push,如下: git commit -a -m "代码日志" git push
补充一下,如果后续有新的程序或文件夹需要提交到gitee,在git commit之前先git add . 一下; 如果gitee上有某个程序文件或文件夹,要新提交的代码中没有该程序文件夹,那么git commit -a -m “”即可
ok,goodbye~
|