Compare commits

..

No commits in common. "abf75d636b3919d5f21e6f067e0b6478610227ba" and "dcc7397232ab72ed61bc639356296b8fb0cbf45f" have entirely different histories.

2 changed files with 7 additions and 6 deletions

View File

@ -23,10 +23,12 @@ get_blob () { # get the blob of the file(name) passed as $1
} }
get_commit_for_blob () { get_commit_for_blob () {
if [ ! -z $1 ]; then
# search for the blob in all commits for the file(name) $1 # search for the blob in all commits for the file(name) $1
echo $(echo $(git log --all --pretty=format:%H -- $1) | echo $(echo $(git log --all --pretty=format:%H -- $1) |
xargs -I{} bash -c "git ls-tree {} -- $1 | xargs -I{} bash -c "git ls-tree {} -- $1 |
grep -q $1 && echo {}") grep -q $1 && echo {}")
fi
} }
changed_file_names () { changed_file_names () {
@ -47,7 +49,7 @@ for fn in $(git diff-tree -r HEAD@{1} HEAD --name-only); do
blob=$(get_blob "$fn") blob=$(get_blob "$fn")
commit=$(get_commit_for_blob $blob) commit=$(get_commit_for_blob $blob)
fsize=$(ls -l "$fn" | awk '{ print $5 }') fsize=$(ls -l "$fn" | awk '{ print $5 }')
echo "$fn $fsize b=$blob c=$commit" >> $GIT_PULL_TMP echo "$fn $fsize $blob $commit" >> $GIT_PULL_TMP
fi fi
fi fi
if grep -E -q ".*opkg_commands" <<< $fn; then if grep -E -q ".*opkg_commands" <<< $fn; then

View File

@ -7,4 +7,3 @@ yyyyy
rrrr rrrr
uuuu uuuu
hhhhhhhhhhhhhhhhhh hhhhhhhhhhhhhhhhhh
uuuuuu