• 博客园logo
  • 会员
  • 众包
  • 新闻
  • 博问
  • 闪存
  • 赞助商
  • HarmonyOS
  • Chat2DB
    • 搜索
      所有博客
    • 搜索
      当前博客
  • 写随笔 我的博客 短消息 简洁模式
    用户头像
    我的博客 我的园子 账号设置 会员中心 简洁模式 ... 退出登录
    注册 登录
Code Live
博客园    首页    新随笔    联系   管理    订阅  订阅
Git学习笔记与bug记录

注意:

Win7上版本号为Git for Windows 2.16.1(2)有以下这个bug

在Git Bash上执行pull时报错:

error: cannot spawn git: Function not implemented

目前解决方法是退回到上一个版本。
 
1. 安装git
2. git --version 查看版本信息,确认安装成功
3. cd到当前文件夹下
4. git init 初始化本地git仓库
5. 配置用户信息
6. git config --global user.name ''
7. git config --global user.email ''
8. git add <file> 添加文件(index.html,*.html,.)
9. git rm --cached <file> 删除文件
10. git status 查看状态
11. git commit -m "message" 提交
12. git push 推送到仓库
13. git pull 从远程仓库拉取数据
14. git clone github中复制的url 从远程仓库拷贝数据
15. 在.gitignore文件中写入要忽略的文件的路径
16. git branch 分支名 创建分支
17. git checkout 分支名 切换到分支(默认初始分支为master)
18. git merge 分支名 合并分支
19. 登陆github -> 点击+按钮 -> New repository -> 给新仓库起一个名字并创建
20. 复制"...or push an existing repository from the command line"中的代码,即上传到远程仓库
posted on 2018-02-08 21:24  二姐的菜刀  阅读(476)  评论(0)    收藏  举报
刷新页面返回顶部
博客园  ©  2004-2025
浙公网安备 33010602011771号 浙ICP备2021040463号-3