首先你得有一个github账号,如果没有的话请注册。
github官网:https://github.com
github Desktop下载地址:https://desktop.github.com/
一. 从github官网上clone仓库代码到本地:
-
打开github官网,登录成功后,New repository创建新的仓库,给新创建的仓库命名Rhine.github.io、添加描述(可选)、添加README说明(可选):
创建仓库

2.打开github Desktop,选择Clone a repository:

填入需要从线上clone的repository的名称以及即将存入本地的路径,这里选择D盘下的githubCloneProj文件夹(文件夹需新建)。如果Clone时提示project找不到,那么第一行将github网页上clone or download所提供的网页地址填入:


clone下来的仓库:

3.vscode打开文件夹githubCloneProj:

进行编辑,搭建一个简单的html页面:

4.vscode编辑完毕后,此时可见github Desktop桌面版已经自动将刚才编辑的代码同步完毕:

5.添加描述信息(summary,Description)后,点击Commit to master进行提交:

二、push到github网页上:
-
点击Push origin
正在push.png
-
打开github页面,可见Rhine.github.io仓库已经push成功:
push成功后的github仓库在<a href = "https://github.com/Rhine1/Rhine.github.io">这里</a>。
三、 从github网页上删除某个项目:
-
点击用户头像 -> your profile,查看已有的仓库:
查看仓库
-
点击需要删除的仓库 -> settings:
-
将页面一直下拉到最低端,选择Delete this repository,确认删除即可:

文末:感谢你看到这里,如果有不清楚的地方可以给我留言;如果觉得不错就给我一个喜欢❤吧~
网友评论