window10下使用git时 报错如下:

$ git add readme.txt
warning: LF will be replaced by CRLF in readme.txt.
The file will have its original line endings in your working directory.

意思大概是:LF(换行,Line Feed)将会被CRLF(回车换行,CarriageReturn)替代。

该文件将在工作目录中具有其原始行尾。

报这个警告时是由于文件夹远程不存在,但是不影响提交

解决办法:

$ rm -rf .git  // 删除.git
$ git config --global core.autocrlf false //禁用自动转换

然后重新执行:

$ git init
$ git add 文件名

windows10下git报错warning: LF will be replaced by CRLF in readme.txt. The file will have its original line endings in your working directory.的更多相关文章

  1. [已解决]报错: warning: LF will be replaced by CRLF in lib/anime.min.js

    git config --global core.autocrlf false

  2. 错误 warning: LF will be replaced by CRLF in README.md.

    问题类型 windows中的换行符为 CRLF, 而在Linux下的换行符为LF,所以在执行add . 时出现提示:warning: LF will be replaced by CRLF in RE ...

  3. 解决git报错“The file will have its original line endings in your working directory”的方法

    在执行命令 git commit --all -m  '说明' 时报错“The file will have its original line endings in your working dir ...

  4. [Git add . ] 遇到The file will have its original line endings in your working directory 解决办法

    1.在新项目中使用[ git add . ]时出现: warning: LF will be replaced by CRLF in ...... The file will have its ori ...

  5. Git提交时提示‘The file will have its original line endings in your working directory’

    Git提交时提示'The file will have its original line endings in your working directory' Git出现错误 git add -A ...

  6. git出现“The file will have its original line endings in your working directory”错误

    一.现象: git add *时出现如下现象: The file will have its original line endings in your working directory 解决: G ...

  7. git提交时”warning: LF will be replaced by CRLF“提示

    今天把项目做完之后,然后用Git准备提交代码的时候,遇到warning: LF will be replaced by CRLF警告. 当时在网上查了资料,发现很多的解决办法都是:修改git全局配置, ...

  8. git 提交报错 : The file will have its original line endings in your working directory.

    报错现象 git  add . 的时候发现此报错 报错分析 看情况应该是不同系统对换行的识别不到位导致的 就常识来说文件是在windows下生成的所以换行和 linux 确实不同可能是因为这个导致的 ...

  9. Git warning:LF will be replaced by CRLF in readme.txt的原因与解决方案

    今天用Git bash遇到的问题,看了几个回答之后发现一个比较有价值的,给大家分享一下,其他很多的回答都有很或多或少存在一些弊端. 原回答地址在stackoverflow上,附上链接--http:// ...

随机推荐

  1. 9. CTF综合靶机渗透(二)

    靶机说明 Welcome to the world of Acid. Fairy tails uses secret keys to open the magical doors. 欢迎来到酸的世界. ...

  2. hdu1074

    #include <iostream> #include <string> #include <cstring> #include <stack> #i ...

  3. PLSQL Developer 直接用ip访问指定数据库

  4. adnroid 启动是没有标题栏

    <activity android:name=".MainActivity" android:theme="@android:style/Theme.Light.N ...

  5. cookie中存取中文字符

    1.存入中文: Cookie c = new Cookie("username", java.net.URLEncoder.encode(name,"utf-8" ...

  6. 使用 PHPMailer 发送邮件出现诡异bug,间歇性发送失败

    场景 使用PHPMailer的SMTP发送邮件,用的是腾讯企业邮箱 smtp.exmail.qq.com 在邮箱设置里看到配置smtp方法 问题描述 本地windows开发环境发送邮件100%成功 远 ...

  7. 菜鸟眼中的”AppSettings和ConnectionStrings“

    前言 这次的机房收费系统重构,我们用到了这个配置文件.瞬间感觉高大上了许多,对新鲜的事务就是又陌生又好奇,通过看静静的博客,还有自己查资料花了点时间弄了弄,下面是我整理的结果. 内容 是什么 AppS ...

  8. 清北刷题冲刺 11-03 p.m

    三向城 #include<iostream> #include<cstdio> using namespace std; int n,x,y; int main(){ freo ...

  9. Linux安装 oracle 11g r2

    Linux环境配置 OS:Fedora 15 DB:Oracle 11gR2 将Oracle安装到home/oracle_11目录 配置过程:本文来自Oracle官方文档+网上资料 Oracle官方文 ...

  10. spark sql metastore 配置 mysql

    本文主要介绍如何为 spark sql 的 metastore 配置成 mysql . spark 的版本 2.4.0 版本 hive script 版本为 hive 1.2.2 mysql 为 5. ...