原文地址:CSDN:yujunf

错误信息:

Counting objects: 9, done.
Delta compression using up to 2 threads.
Compressing objects: 100% (5/5), done.
Writing objects: 100% (5/5), 506 bytes, done.
Total 5 (delta 2), reused 0 (delta 0)
error: insufficient permission for adding an object to repository database ./objects
fatal: failed to write object
error: unpack failed: unpack-objects abnormal exit

原因:

git库权限的问题

$ ls -la #查看git库的所有者

解决:

在git库目录下:

$sudo chown -R git:git [你的git库,即项目]