git update-index --assume-unchanged
有的时候,不小心提交了一个配置文件config.php,每次在本地开发测试之后,都需要更改配置文件。相当麻烦。
使用
git update-index --assume-unchanged /path/file 可以忽略这个修改。从而不用提交到库里面。
字面意思很好理解
assume 假设
unchanged 未更改。
如果想恢复该文件,可以用
git update-index --no-assume-unchanged /path/file 来恢复跟踪
但是有个问题。如何更改让其他协同开发的同事也能生效,从而避免提交该文件呢?
git update-index --assume-unchanged的更多相关文章
- [转]使用Maven添加依赖项时(Add Dependency)时,没有提示项目可用,并且在Console中,输出: Unable to update index for central|http://repo1.maven.org/maven2 。
使用Maven添加依赖项时(Add Dependency)时,没有提示项目可用,并且在Console中,输出: Unable to update index for central|http://re ...
- git “bad index file sha1 signature fatal: index file corrupt”错误
在执行commit或revert等操作时,提示“bad index file sha1 signature fatal: index file corrupt”错误,导致操作失败.这是由于git的in ...
- Unable to update index for central
Unable to update index for central http://repo1.maven.org/maven2/ 就是这句,myeclipse启动后控制台输出这句话:解决办法:1.在 ...
- Android Studio 通过 git update 或者 pull 的时候出错及解决办法
Android Studio 通过 git update 或者 pull 的时候出错,log 如下: Couldn't save uncommitted changes. Tried to save ...
- 解决eclipse安装maven的问题:Unable to update index for central|http://repo1.maven.org/maven2
问题产生如下:因为单位使用了过滤,访问Internet时,超过10M的内容就拒绝.因为maven插件在初始时,需要下载Maven的index文件,这个文件比较大,有38M多,下载不成功.所以造成使用M ...
- Unable to update index for central http://repo1.maven.org/maven2/ 解决方法
不知道什么原因 MyEclipse(eclipse) 中的 maven 插件突然不能用了,修改 pom.xml 无任何反应 控制台报 Unable to update index for centra ...
- 解决MyEclipse开启后总是不停的在Update index
近期MyEclipse开启之后总是不停的在 update index,非常是耗时间. 查找资料发现Update index...是Maven在不断更新, 解决的方法例如以下: Window --> ...
- Unable to update index for nexus-publish | http://ip:port/repository/maven-public/
问题描述:Unable to update index for nexus-publish | http://ip:port/repository/maven-public/ 解决方案:进入工作空间. ...
- [MongoDB] Query, update, index and group
/* 1. Query Operators */ db.posts.find({ viewsCount: {$get: 1000, $lte: 3000} }, {_id: 0, viewsCount ...
- 彻底解决m2eclipse之Unable to update index for central
原文链接:https://my.oschina.net/itblog/blog/208581 maven是个好东西,eclipse上的maven插件m2eclipse也非常方便,但是最近这个东西经常无 ...
随机推荐
- Directx11教程(54) 简单的基于GS的billboard实现
原文:Directx11教程(54) 简单的基于GS的billboard实现 本章我们用一个billboard的实现来学习D3D11中的GS. 在VS shader中,我们输入的是顶点 ...
- python 使用自定义的类方法
- python HTTP请求过程
- [React Native]访问操作系统剪贴板 Clipboard
我们之前学习了TextInput组件, 有时候我们需要在TextInput组件中复制或者粘贴一些文字. React Native为开发者提供了 Clipboard API,Clipboard 组件可以 ...
- Gym - 101480K_K - Kernel Knights (DFS)
题意:有两队骑士各n人,每位骑士会挑战对方队伍的某一个位骑士. (可能相同) 要求找以一个区间s: 集合S中的骑士不会互相挑战. 每个集合外的骑士必定会被集合S内的某个骑士挑战. 题解:讲真被题目绕懵 ...
- js+canvas 一只一担小游戏
<!DOCTYPE html> <html> <head> <meta charset="UTF-8"> <title> ...
- jmeter循环取消今天所有的订单
结构 1.首先,添加JDBC Connection Configuration 2.其次添加JDBC request 添加循环控制器 循环控制器下方添加计数器 ${__V(reservationID_ ...
- Spring IoC 使用详解
在Spring中,依赖注入(DI)模式实现了控制反转(IoC)原理.让我们通过一个例子来帮助理解依赖注入.我们先看到java版的例子,然后在此基础上加上spring的功能.就例子而言,是相当地简单.Q ...
- 数据节点Datanodes
- Export与import命令
模块功能主要由两个命令构成:export和import. export命令用于用户自定义模块,规定对外接口: import命令用于输入其他模块提供的功能,同时创造命名空间(namespace),防止函 ...