git push 提示 Everything up-to-date
第一次在 Google Code 上弄项目,注册完毕后,
尝试增加一个新文件用以测试 Git 是否好好工作。
结果在 Push 时却显示 Every up-to-date,检查文件时却发现实际上一个都没更新上去。
因为对 Git 不够熟悉,因此只好 Googling,进行一番搜索后找到原因如下:
Why does Git refuse to push, saying “everything up to date”?
git push with no additional arguments only pushes branches that exist in the remote already.
If the remote repository is empty, nothing will be pushed.
In this case, explicitly specify a branch to push, e.g. git push master.
也就是说一开始 git 服务器仓库是完全空的,
不包含任何一个分支(branch),因此刚开始 Push 时需要指定一个。
执行 git remote -v 后看到自己的 remote 端名字为 origin:
$ git remote -v
origin https://code.google.com/p/micolog2 (fetch)
origin https://code.google.com/p/micolog2 (push)
执行 git branch 后看到自己当下用的分支是 master:
$ git branch
* master
因此在本地 commit 后,再执行 git push origin master 即可。
git push 提示 Everything up-to-date的更多相关文章
- git push 提示
我运行git push -u origin master 时提示如下: To git@github.com:userName/project.git ! [rejected] master -> ...
- git push提示或错误
当 git 和 gerrit 一起使用的时候,你创建了一个 tag,现在需要 push 到远程仓库,当你没有权限的时候,会出现如下提示: $ git push origin v20150203 Tot ...
- Git push提示pre-receive hook declined
master:local auto@ubuntu:~/src/code/ git push Counting objects: 5, done. Delta compression using up ...
- windows 切换git远程仓库地址后 git push 提示Authentication failed
git切换远程分支: 方法一: git remote set-url origin 你新的远程仓库地址 方法二: git remote rm origin git remote add origin ...
- 转 git push 提示 Everything up-to-date
git 还没有分支,需要指定一个($ git remote -v),就可以push了 第一步:$ git remote -v 第二步:$ git branch 转载链接: http://blog.cs ...
- Git Push提示没有权限
中途协助别人开发的一个小项目, 我已经是该项目的Developer, 可是提交代码依然提示无权限 这是由于我是在master上直接提交的, 而GitLab默认是保护master分支的, push只对M ...
- git push时提示"fatal: The current branch master has no..."
git push到远程仓库时提示:fatal: The current branch master2 has no upstream branch. To push the current branc ...
- git push时提示--set-upstream
问题: 提示需要加--set-upstream
- git push提交报错,提示文件过大,且去掉大文件也报同样的错误
错误原因: 大文件存在没有被提交的commit记录里面: 解决方案: 删除有大文件的commit记录即可 移除大文件的正确姿势 $ git rm --cached giant_file(文件名) # ...
随机推荐
- 【UOJ#435】【集训队作业2018】Simple Tree 分块+树链剖分
题目大意: 有一棵有根树,根为 1 ,点有点权.现在有 m 次操作,操作有 3 种:1 x y w ,将 x 到 y 的路径上的点点权加上 w (其中 w=±1w=±1 ):2 x y ,询问在 x ...
- POJ 2316
#include<iostream> #include<stdio.h> #include<string> using namespace std; ]; int ...
- mahout学习
参考:http://www.360doc.com/content/14/0117/09/1200324_345883534.shtml Precondition: 启动Hadoop集群 bin/hdf ...
- 【Java并发编程】:深入Java内存模型——happen-before规则及其对DCL的分析
happen—before规则介绍 Java语言中有一个“先行发生”(happen—before)的规则,它是Java内存模型中定义的两项操作之间的偏序关系,如果操作A先行发生于操作B,其意思就是说, ...
- 【jQuery源码】事件委托
jQuery的事件绑定有几个比较优秀的特点: 1. 可以绑定不限数量的处理函数 2. 事件可以委托到祖先节点,不必一定要绑到对应的节点,这样后添加的节点也照样能被处理. 3. 链式操作 下面主要分析事 ...
- Android 开发工具类 32_通过 HTTP 协议实现文件上传
完成像带有文件的用户数据表单的上传,而且可以上传多个文件,这在用户注册并拍照时尤其有用. import java.io.BufferedReader; import java.io.ByteArray ...
- C/C++ -- Gui编程 -- Qt库的使用 -- Qt窗体的类型状态布局
-----工程WindowTest----- 1.-----窗体类型type.cpp----- #include <QtGui> int main(int argc, char * arg ...
- Centos下Kubernetes+Flannel部署(新)
一.准备工作 1) 三台centos主机 k8s master: 10.11.151.97 tc-151-97 k8s node1: 10.11.151.100 tc-151-100 k8s no ...
- java学习-zxing生成二维码矩阵的简单例子
这个例子需要使用google的开源项目zxing的核心jar包 core-3.2.0.jar 可以百度搜索下载jar文件,也可使用maven添加依赖 <dependency> <gr ...
- [C语言]类型限定词const解析
作为C90增加的一个受限类型关键字,const赋予了它修饰的变量一个新属性——不变性,如果一个变量声明中带有关键字const,则无法通过赋值.增减运算来修改该变量的值. 一.指针与const结合 co ...