mdisk: Remove color from "Already mounted" message
[sunny256-utils.git] / git-all-blobs
blobfd1690f4b9670dbea8c29815e607dbc907305210
1 #!/usr/bin/env bash
3 #=======================================================================
4 # git-all-blobs
5 # File ID: fcc2d334-5b41-11e0-a1bf-00023faf1383
6 # Extract all blobs to blob-dir/
7 # License: GNU General Public License version 2 or later.
8 #=======================================================================
10 mkdir blob-dir
11 rm bad-blobs.txt
12 for f in $( \
13 git log --raw --abbrev=40 --all | \
14 grep ^: | \
15 cut -f 3-4 -d ' ' | \
16 fmt -1 | \
17 sort -u | \
18 grep -v 0000000000000000000000000000000000000000 \
19 ); do
20 echo $f
21 git show $f >blob-dir/$f || echo $f >>bad-blobs.txt
22 done