Git与GitHub学习笔记(五)一次提交失败的记录

简介: 代码已经跟踪了,添加注释说明,但是总是添加不了error: pathspec 'live-page'' did not match any file(s) known to git.重复了好多遍,最后发现代码还是没有提交D:\wamp64\www\study-line>git commi...

代码已经跟踪了,添加注释说明,但是总是添加不了

error: pathspec 'live-page'' did not match any file(s) known to git.

重复了好多遍,最后发现代码还是没有提交

D:\wamp64\www\study-line>git commit -m 'add live-page'
error: pathspec 'live-page'' did not match any file(s) known to git.

D:\wamp64\www\study-line>git add ./

D:\wamp64\www\study-line>git push origin develop
Everything up-to-date

 最后查看了一下当前状态

继续,按照这个总算是提交成功了

D:\wamp64\www\study-line>git status
On branch develop
Your branch is up-to-date with 'origin/develop'.
Changes to be committed:
  (use "git reset HEAD <file>..." to unstage)

        modified:   application/backend/view/common/sidebar.html
        modified:   application/backend/view/linux_shell/internalStorage.html
        modified:   application/backend/view/live/vodEdit.html
        modified:   application/backend/view/live/vodManage.html

D:\wamp64\www\study-line>git reset ./
Unstaged changes after reset:
M       application/backend/view/common/sidebar.html
M       application/backend/view/linux_shell/internalStorage.html
M       application/backend/view/live/vodEdit.html
M       application/backend/view/live/vodManage.html

D:\wamp64\www\study-line>git status
On branch develop
Your branch is up-to-date with 'origin/develop'.
Changes not staged for commit:
  (use "git add <file>..." to update what will be committed)
  (use "git checkout -- <file>..." to discard changes in working directory)

        modified:   application/backend/view/common/sidebar.html
        modified:   application/backend/view/linux_shell/internalStorage.html
        modified:   application/backend/view/live/vodEdit.html
        modified:   application/backend/view/live/vodManage.html

no changes added to commit (use "git add" and/or "git commit -a")

D:\wamp64\www\study-line>git add ./

D:\wamp64\www\study-line>git commit -m "add CDN page"
[develop 0be7d2a] add CDN page
 4 files changed, 9 insertions(+), 14 deletions(-)

D:\wamp64\www\study-line>git push origin develop
Counting objects: 12, done.
Delta compression using up to 4 threads.
Compressing objects: 100% (12/12), done.
Writing objects: 100% (12/12), 1.09 KiB | 0 bytes/s, done.
Total 12 (delta 11), reused 0 (delta 0)
remote: Resolving deltas: 100% (11/11), completed with 11 local objects.
remote: This repository moved. Please use the new location:
remote:   https://github.com/Tinywan/study-line.git
To https://github.com/Tinywan/study-line.git
   283c67f..0be7d2a  develop -> develop

 

目录
相关文章
|
17天前
|
人工智能 API 开发工具
GitHub官方开源MCP服务!GitHub MCP Server:无缝集成GitHub API,实现Git流程完全自动化
GitHub MCP Server是基于Model Context Protocol的服务器工具,提供与GitHub API的无缝集成,支持自动化处理问题、Pull Request和仓库管理等功能。
295 2
GitHub官方开源MCP服务!GitHub MCP Server:无缝集成GitHub API,实现Git流程完全自动化
|
13天前
|
文字识别 网络协议 开发工具
GitHub封锁?推荐5个国产的Git仓库替代平台
近日,GitHub对中国区IP的部分限制引发了广泛关注。未登录用户被拒,已登录用户功能受限,南北网络环境差异更显“内卷”。为应对这一挑战,本文推荐了多个国产Git平台:Gitee(码云)、GitCode(CSDN旗下)、CODING(腾讯系)、CodeUP(阿里云支持)及微信代码管理工具。这些平台功能全面、稳定性强,是开发者迁移项目的理想选择。通过同步代码、配置CI/CD流水线等简单步骤,可确保项目平稳过渡。此次事件提醒我们,掌握核心技能与支持国产平台同样重要!
118 11
|
22天前
|
安全 Linux 网络安全
在Linux(CentOS和AWS)上安装更新的git2的方法并配置github-ssh
经过以上这些步骤,你现在就能在GitHub上顺利往返,如同海洋中的航海者自由驰骋。欢迎你加入码农的世界,享受这编程的乐趣吧!
51 10
|
3月前
|
开发工具 git
如何操作github,gitee,gitcode三个git平台建立镜像仓库机制,这样便于维护项目只需要维护一个平台仓库地址的即可-优雅草央千澈
如何操作github,gitee,gitcode三个git平台建立镜像仓库机制,这样便于维护项目只需要维护一个平台仓库地址的即可-优雅草央千澈
277 69
如何操作github,gitee,gitcode三个git平台建立镜像仓库机制,这样便于维护项目只需要维护一个平台仓库地址的即可-优雅草央千澈
|
2月前
|
网络安全 开发工具 git
解决 Git 访问 GitHub 时的 SSL 错误
通过上述步骤,可以有效解决 Git 访问 GitHub 时的 SSL 错误。推荐优先更新 CA 证书和正确配置 Git 使用 CA 证书,避免禁用 SSL 验证。如果问题持续,可以切换到 SSH 方式访问 GitHub,确保连接的安全性和稳定性。希望这些内容对您的学习和工作有所帮助。
240 3
|
3月前
|
Devops Shell 网络安全
git使用之如何将一套代码同时推送至github|gitee|gitcode|gitlab等多个仓库-含添加ssh-优雅草央千澈完美解决-提供整体提交代码
git使用之如何将一套代码同时推送至github|gitee|gitcode|gitlab等多个仓库-含添加ssh-优雅草央千澈完美解决-提供整体提交代码
169 16
git使用之如何将一套代码同时推送至github|gitee|gitcode|gitlab等多个仓库-含添加ssh-优雅草央千澈完美解决-提供整体提交代码
|
5月前
|
Linux 网络安全 开发工具
Git学习笔记(一):基础与应用
本文档详细介绍了如何将本地项目关联到Gitee上的空仓库并上传代码,以及如何验证本机与Git服务器的SSH连接。同时,还概述了Git的基本概念、安装步骤、初始配置、常见命令及如何配置多个SSH-Key,适用于初学者快速上手Git操作。
183 51
Git学习笔记(一):基础与应用
|
5月前
|
网络安全 开发工具 git
解决fatal:remote error:You can’t push to git://github.com/username/*.g
通过上述诊断与修复步骤,绝大多数的推送错误都能得到有效解决,确保您的Git工作流顺畅无阻。
352 1
|
5月前
|
Linux 网络安全 开发工具
IDEA如何配置git和github
【11月更文挑战第14天】本指南详细介绍了如何在 IntelliJ IDEA 中配置 Git 和 GitHub,包括检查和设置 Git 路径、测试配置,以及通过 SSH 或 HTTPS 方式配置 GitHub 仓库的具体步骤。完成配置后,用户可在 IDEA 中轻松进行版本控制操作。
852 0
|
6月前
|
Unix Shell 网络安全
git学习六:(bug总结)git@github.com: Permission denied (publickey).等
本文是关于解决在使用Git和GitHub时遇到的“git@github.com: Permission denied (publickey)”错误的指南。文章提供了详细的步骤,包括确认SSH Agent运行状态、检查密钥配置、确保密钥匹配、验证仓库URL、检查权限和代理设置,以及配置SSH文件。这些步骤帮助用户诊断并解决SSH认证问题。
818 0
下一篇
oss创建bucket