git diff比较使用
git diff 等同于 git diff HEAD
jiqing@ubuntu:/home/wwwroot/default/siemens/new_hotel$ git diff HEAD
diff --git a/Index/Lib/Action/GetDataAction.class.php b/Index/Lib/Action/GetDataAction.class.php
index 1550a57..0f79846 100644
--- a/Index/Lib/Action/GetDataAction.class.php
+++ b/Index/Lib/Action/GetDataAction.class.php
@@ -60,8 +60,16 @@ class GetDataAction extends Action{
}
/**
- * 获取统计数据
- *
+ * 统计数据展示
+ * 1 点我制作
+ * 2 开始
+ * 3 马上拍照
+ * 4 上一步
+ * 5 生成
+ * 6 重做
+ * 7 分享
+ * 8 ~ 26 (7 + i) 19个贴纸的点击,i为贴纸的id
+ * 27 ~ 45 ( 26 + i) 19个贴纸的使用,i为贴纸的id
*/
具体的某个版本与版本之间可以比较
jiqing@ubuntu:/home/wwwroot/default/siemens/new_hotel$ git diff HEAD^ HEAD^^
diff --git a/Index/Lib/Action/GetDataAction.class.php b/Index/Lib/Action/GetDataAction.class.php
index 1550a57..d997bcd 100644
--- a/Index/Lib/Action/GetDataAction.class.php
+++ b/Index/Lib/Action/GetDataAction.class.php
@@ -17,8 +17,9 @@ class GetDataAction extends Action{
* 5 生成
* 6 重做
* 7 分享
- * 8 ~ 26 (7 + i) 19个贴纸的点击,i为贴纸的id
- * 27 ~ 45 ( 26 + i) 19个贴纸的使用,i为贴纸的id
+ * 8 点我制作
+ * 9 ~ 27 (8 + i) 19个贴纸的点击,i为贴纸的id
+ * 28 ~ 46 ( 27 + i) 19个贴纸的使用,i为贴纸的id
*/
public function get_data(){
if(trim($_POST['type'])){
@@ -58,15 +59,4 @@ class GetDataAction extends Action{
send_http_status(200);
}
}
前后顺序无所谓
jiqing@ubuntu:/home/wwwroot/default/siemens/new_hotel$ git diff HEAD^^ HEAD^
diff --git a/Index/Lib/Action/GetDataAction.class.php b/Index/Lib/Action/GetDataAction.class.php
index d997bcd..1550a57 100644
--- a/Index/Lib/Action/GetDataAction.class.php
+++ b/Index/Lib/Action/GetDataAction.class.php
@@ -17,9 +17,8 @@ class GetDataAction extends Action{
* 5 生成
* 6 重做
* 7 分享
- * 8 点我制作
- * 9 ~ 27 (8 + i) 19个贴纸的点击,i为贴纸的id
- * 28 ~ 46 ( 27 + i) 19个贴纸的使用,i为贴纸的id
+ * 8 ~ 26 (7 + i) 19个贴纸的点击,i为贴纸的id
+ * 27 ~ 45 ( 26 + i) 19个贴纸的使用,i为贴纸的id
*/
public function get_data(){
if(trim($_POST['type'])){
@@ -59,4 +58,15 @@ class GetDataAction extends Action{
send_http_status(200);
}
}
git diff 分支1 分之2
看详细差异
jiqing@ubuntu:/home/wwwroot/default/siemens/new_hotel$ git diff siemens master
diff --git a/.gitignore b/.gitignore
index 8f32300..6655344 100755
--- a/.gitignore
+++ b/.gitignore
@@ -49,8 +49,6 @@ Shop/Runtime
*/*~
Public/Public
Public/upload/bgimg/*
-Public/log/*
-Public/tmp/*
!Public/upload/bgimg/.tmp
.settings/
diff --git a/Index/Conf/config.php b/Index/Conf/config.php
index 4fd4d44..3124482 100644
--- a/Index/Conf/config.php
+++ b/Index/Conf/config.php
@@ -1,13 +1,4 @@
git diff 分支1 分之2 --stat
看大局差异
jiqing@ubuntu:/home/wwwroot/default/siemens/new_hotel$ git diff siemens master --stat
.gitignore | 2 -
Index/Conf/config.php | 21 +-
Index/Lib/Action/CommonAction.class.php | 61 +--
Index/Lib/Action/GetDataAction.class.php | 72 ---
Index/Lib/Action/SiemensAction.class.php | 715 ----------------------------
Index/Tpl/Circus/index.html | 3 +-
Index/Tpl/Siemens/index.html | 327 -------------
Index/Tpl/Siemens/share.html | 54 ---
Public/MP_verify_HIkhmwma5QBj98ns.txt | 1 -
Public/index.php | 4 +-
Public/siemens/css/.font-spider/PingFang ExtraLight.ttf | Bin 11035472 -> 0 bytes
Public/siemens/css/.font-spider/wryh.ttf | Bin 15043584 -> 0 bytes
Public/siemens/css/animate.css | 3279 -------------------------------------------------------------------------------------------------------------------------------
Public/siemens/css/animate.min.css | 6 -
Public/siemens/css/index.css | 605 ------------------------
Public/siemens/css/index.scss | 540 ---------------------
Public/siemens/css/reset.min.css | 2 -
Public/siemens/css/swiper.min.css | 15 -
Public/siemens/css/zepto.plugin.css | 87 ----
Public/siemens/css/zepto.plugin.scss | 87 ----
Public/siemens/font/msyh.ttf | Bin 21767952 -> 0 bytes
还可以进行本地分支与线上分支的比较
jiqing@ubuntu:/home/wwwroot/default/5hao/sheep-doc$ git diff origin/5hao
diff --git a/cart.md b/cart.md
index 0174a54..b2861b3 100644
--- a/cart.md
+++ b/cart.md
@@ -80,7 +80,6 @@ uid 有则传,无则不传
"name": "法兰西苹果",
"has_activity": 0,
"id": "1", // 商品id
- "type":"1", //type:1.自营商品;2.积分好货
"collection" : 1
"is_relation_attr": [
{
@@ -111,7 +110,6 @@ uid 有则传,无则不传
"has_activity": 0,
"collection" : 1
"id": "2",
- "type":"2", //type:1.自营商品;2.积分好货
"is_relation_attr": [
{
"name": "产地",
默认拿当前本地版本对比线上的最新版本。
如果有一段时间,没有更新,则需要处理一下,才能对比出最新的代码。
git fetch origin
git diff yanglu origin/gaodian
或者只看文件
git diff yanglu origin/gaodian --stat
git diff比较使用的更多相关文章
- git diff 生成patch, git apply patch 打补丁方法说明,以及分支管理的简单操作。
git diff 简易操作说明 先git log 查看commit ID, 记录你想要打的补丁的ID 比如说: git log commit 4ff35d800fa62123a28b7bda2a04e ...
- Saving the entire git diff between two commits in a text file
git diff A10..A1 > my.diff 转自: http://stackoverflow.com/questions/19067896/saving-the-entire-git- ...
- git diff ^M的消除
这是由于换行符在不同的操作系统上定义的区别造成的. Windows用CR LF来定义换行,Linux用LF. CR全称是Carriage Return ,或者表示为\r, 意思是回车. LF全称是Li ...
- 基于git diff进行的eslint代码检测
缘起 在项目中, 通常都会使用代码检测工具来规范团队的代码风格, 比如eslint.随着代码的不断增加, eslint进行代码检测的时间也越来越久.每次检测的时候, 需要检测的文件和实际检测的文件极度 ...
- git diff提示filemode发生改变(old mode 100644、new mode 10075)
今天clone代码,git status显示修改了大量文件,git diff提示filemode变化,如下: diff --git a/Android.mk b/Android.mkold mode ...
- git diff的用法
在git提交环节,存在三大部分:working tree(工作区), index file(暂存区:stage), commit(分支:master) working tree:就是你所工作在的目录, ...
- git diff
git diff 工作区与暂存区的差别 git diff -cached / git diff -staged 暂存区与版本库的差别 git diff HEAD 工作区与版本库的差别 git d ...
- git diff获取差异文件中文乱码的解决办法
通过git的diff命令对两个commit id的版本进行差异化的对比.中文文件时出现乱码. git diff 6bded8d0c1fe1746c122121217dc0c88667091089 a9 ...
- Git diff 常见用法
Git diff 用于比较两次修改的差异 1.1 比较工作区与暂存区 git diff 比较的是单个仓库的工作区与暂存区的差别,repo diff是对git diff的封装,用来分别显示各个项目 ...
- git diff patch
如何生成patch:修改一个地方,然后git diff > xxx.patch 就会生成一个patch文件,这里的关键似乎是, 源文件的某个模块的版本要和线上发布的最新版本要一致,这样patch ...
随机推荐
- 浅谈:nodejs在cmd提示不是内部或外部命令
今天用cmd安装个库,结果发现node不是内部命令,检查后发现上次重装nodejs换了个安装位置,path环境变量忘改了. 找到变量值中node的安装地址,比如C:develop\nodejs,如果不 ...
- 数据导出为Excel(未完)
更多详细内容 view页面: function Download() { //多个查询条件 dateStart = $("#j_dataTimeStart").datebox(&q ...
- 网络编程 - socket实现多个连接处理
#服务端import socket,osso_server=socket.socket()so_server.bind(("localhost",6969))so_server.l ...
- 小程序 textarea ios兼容解决
今天遇到,在小程序里textarea会存在一定的兼容性问题,textarea有默认的内边距,在安卓和ios显示的时候,ios边距会比安卓的大很多. 解决办法: 通过 wx.getSystemInfoS ...
- 洛谷——P1594 护卫队
P1594 护卫队 题目描述 护卫车队在一条单行的街道前排成一队,前面河上是一座单行的桥.因为街道是一条单行道,所以任何车辆都不能超车.桥能承受一个给定的最大承载量.为了控制桥上的交通,桥两边各站一个 ...
- react-router v4 学习实践
最近学习了 react-router v4,根据官方 API 文档和网上资源做了一个简单的路由示例. 先用官方的工具 create-react-app 初始化一个 react 项目模板,再根据自己的 ...
- LINUX-文件的权限 - 使用 "+" 设置权限,使用 "-" 用于取消
ls -lh 显示权限 ls /tmp | pr -T5 -W$COLUMNS 将终端划分成5栏显示 chmod ugo+rwx directory1 设置目录的所有人(u).群组(g)以及其他人(o ...
- BZOJ 1370 团伙
两个认识的人不是朋友就是敌人,且满足: 1,朋友的朋友是朋友: 2,敌人的敌人是朋友. 一群朋友组成一个团伙,给出m个信息,求有多少个团伙. 用并查集,把一个点x拆成x和x’ 若a与b为朋友,则将a与 ...
- 51NOD 1183编辑距离(动态规划)
>>点击进入原题测试<< 思路:这个题放在基础题,分值还是零分,好歹也给人家动态规划一点面子啊!刚开始写的想法是找到其最大公共字串,然后用两个字符串中最长字符串的长度减掉最大公 ...
- springcloud(八):熔断器Hystrix
熔断器 雪崩效应 在微服务架构中通常会有多个服务层调用,基础服务的故障可能会导致级联故障,进而造成整个系统不可用的情况,这种现象被称为服务雪崩效应.服务雪崩效应是一种因“服务提供者”的不可用导致“服务 ...