Git

2 items

Jé pa l'temps #33 - Clean big files in git

Basically the job is done with a command called git filter-branch

1git filter-branch --force --index-filter "git rm --cached --ignore-unmatch static/\*" --prune-empty --tag-name-filter cat -- --all
1git filter-repo --strip-blobs-bigger-than 10M

Sources

— — — — — — — — — — — — — — — — — — — — —

La série « Jé pa l’temps » est une série de tutoriels rapides en mode “prise de note” pour avoir une trace de tout ce dont je ne peux me rappeler et pourquoi pas le partager à d’autre. On va à l’essentiel, laissons les jolis pavés à d’autres sites comme medium… LOL !

Read more →
jplt git

Jé pa l'temps #12 - Quickly find a bug using git bisect

Git bisect is an useful command that helps you to quickly find a bug by dichotomy

Usage

git bisect start

Target a bad commit, usually it is HEAD (because you just realized your code is bugged)

git bisect bad HEAD

Then, give a good commit where you code works as you expect

git bisect good 429761c # Exemple of a hash commit

All is setup ! Now, you just have to test your code and then tell to git if the code is good or not.

Read more →
jplt git