holman / holman/dotfiles

zero padded filemode in your git history

Open
#231 7 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Shell
Stars
7.8k
Forks
3.2k
PR merge metrics
No merged PRs in 30d

Description

Trying to clone dotfiles with modern (well, fine bleeding edge) git fails:

✔ ~ 
00:39 $ git clone https://github.com/holman/dotfiles.git
Cloning into 'dotfiles'...
remote: Counting objects: 2026, done.
error: object 3aadee53f1ea498f2e496d63ac24cf28b358b9b7: zeroPaddedFilemode: contains zero-padded file modes
fatal: Error in object
fatal: index-pack failed

This seems to be due to a bug from 2005 + closing a security hole https://www.perforce.com/blog/150109/git-out-vulnerability-out-fire.

git config fetch.fsckObjects false

Will allow the repo to be cloned, but presumably there is a reason the default has been changed to true.

If you follow the directions (git fast-export --all | (cd ../myFixedRepo; git fast-import)) the issue seems to start very early in the history.

I have pushed the cleaned version here

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the failure by cloning the repository with fetch.fsckObjects enabled, then inspect the early history where the zero-padded file mode appears. Compare the fast-export/fast-import result described in the issue and verify that the resulting repository clones successfully without the zeroPaddedFilemode error.

Written by the indexing model from the issue text.

Assessment

Tech stack
git, shell
Domain
devtools
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.