1. 在node.js开发的时候常常会遇到从别人的远程仓库中clone时出现文件名过长的错误,

或则是在本地npm下载之后的文件进行上传到自己的远程仓库的时候会出现 File too long的情况,这个时候(例如:mongoose的模块,less模块)

可以在git bash中先运行下面这行命令:

     git config --global core.longpaths true,

这样基本上可以解决问题。

  2. 如果对于非必要处理的文件文件可以利用.gitignore文件来忽略文件的上传到git远程仓库,

    具体介绍谷一下就行了,或则找一下度娘就解决。

  3. npm下载或遇到下载不下来的时候可以考虑淘宝镜像cnpm

    npm install -g cnpm --registry=https://registry.npm.taobao.org

  4. git提交的时候出现这种错误的时候:

  “If no other git process is currently running, this probably means a
  git process crashed in this repository earlier. Make sure no other git
  process is running and remove the file manually to continue.”   解决方法:
    git bash 中输入:
rm -f ./.git/index.lock  5.git push 或者是 git pull 的时候出现下面报错

    Could not read from remote repository.

    Please make sure you have the correct access rights.and the repository exists.

    出现这个问题可能是因为,没有在github账号添加SSH key,或是因为重装系统等原因导致密钥与公钥丢失。需重新创建密钥与公钥

   解决方法:

      打开git bash(不可以是windows系统的cmd命令行):  ssh-keygen -t rsa -C "your_email@xxx.com"

      之后创建的三个回车,

      创建好后会默认在系统盘中创建一个公钥文件一般情况在 C:\Users\主机名\.ssh 文件夹下有一个这个 id_rsa.pub 文件
      用记事本或者文本编辑器打开选中里面的所有内容  或者  命令行输入 pbcopy < ~/.ssh/id_rsa.pub 直接复制到剪切板上

      然后到自己的github中设置中添加SSH keys




git处理时的问题的更多相关文章

  1. Git push 时每次都需要密码的疑惑

    2015.1.13更新: 在本地搭建Git服务器时,也是有每次操作需要密码的情况. 是因为每次做推送动作时,Git需要认证你是好人.所以需要密码. 可以在 /home/username/.ssh/au ...

  2. 设置Git提交时不用输入用户名和密码

    在用git提交时代码至github上时每次都要输入用户名和密码,当提交操作较为频繁时非常不方便,可以按下文中的介绍,设置成提交时不用输入用户名和密码: 1.在当前库下,已经运行过 git remote ...

  3. git clone时出现 error:inflate:data stream error(incorrect data check)

    git clone时出现 error:inflate:data stream error(incorrect data check) fatal:serrious inflate inconsiste ...

  4. 执行Git命令时出现各种 SSL certificate problem 的解决办法

    执行Git命令时出现各种 SSL certificate problem 的解决办法 来源  https://www.cnblogs.com/chenzc/p/5842932.html 比如我在win ...

  5. MAC OS 更新GIT版本时遇到的问题

    在更新git版本时,没有备份就删掉了原先的版本,在安装完2.18.0的新版本后,使用命令行git --version,返回错误git not a developer tool or in PATH. ...

  6. git pull时解决分支分叉(branch diverged)问题

    git pull时出现分支冲突(branch diverged) $ git status # On branch feature/worker-interface # Your branch and ...

  7. 解决git pull时出现的几个问题

    第1个问题: 解决GIT代码仓库不同步 今天在执行git pull时出现: 解决方法:执行git checkout -f,然后再执行git pull重新checkout 再执行git pull时就可以 ...

  8. (诊断)git review时出现fatal: ICLA contributor agreement requires current contact information.错误

    使用git review时出现错误: fatal: ICLA contributor agreement requires current contact information. Please re ...

  9. git push时提示"Everything up-to-date"

    从github上git clone下的项目,添加或修改文件后,git push时出现"Everything up-to-date" ,   即“一切都是最新的'. 通过 git s ...

  10. 如何修改git push时的密码

    如何修改git push时的密码 如下: 打开git bash 输入 cd ~/.ssh ls 确定有 id_rsa 和 id_rsa.pub文件 ssh-keygen -p -f id_rsa 第一 ...

随机推荐

  1. BZOJ2599:[IOI2011]Race

    浅谈树分治:https://www.cnblogs.com/AKMer/p/10014803.html 题目传送门:https://www.lydsy.com/JudgeOnline/problem. ...

  2. Spring 注释标签@Resource @Autowired 和@Inject的区别

    一些spring的开发人员在使用这三个标签进行注入的时候感到困惑.我来尝试解释一下这三个注解的主要区别.事实上,这三者非常相似,只存在一些微小的差别.在稍后的文章中会进行解释. @Resource-在 ...

  3. myeclipse配置

    windows->preference->MyEclipse->servers->tomcat 选项下 Tomcat 6.x 点 enable 设置tomcat directo ...

  4. NLTK vs SKLearn vs Gensim vs TextBlob vs spaCy

    Generally, NLTK is used primarily for general NLP tasks (tokenization, POS tagging, parsing, etc.) S ...

  5. Linux命令行设置环境变量

    参考  Linux命令行--使用linux环境变量  Linux命令行—使用Linux环境变量

  6. 利用python数据分析panda学习笔记之基本功能

    1 重新生成索引 如果某个索引值不存在就引入缺失值 from pandas import Series,DataFrame import pandas as pd import numpy as np ...

  7. 20个Flutter实例视频教程-第06节: 酷炫的路由动画-2

    博客地址: https://jspang.com/post/flutterDemo.html#toc-94f 视频地址: https://jspang.com/post/flutterDemo.htm ...

  8. 138. Copy List with Random Pointer (not do it by myself)

    A linked list is given such that each node contains an additional random pointer which could point t ...

  9. WPF 设置 Label.MouseDoubleClickEvent

    facLabel.AddHandler(Label.MouseDoubleClickEvent, new MouseButtonEventHandler((o, a) => { facLabel ...

  10. 端口渗透·网站渗透过程 --21 ,22,873,3306,6379,8080(8080端口是针对CMS的渗透)

    声明:文章渗透网站为模拟环境,文章只为利用过程 文章为信息收集和端口渗透两部分,21端口为ftp版本漏洞 8080端口为CMS的渗透 信息收集: ·使用扫描工具nmap ,PortScan 对整个网段 ...