Categories:
Posted by: bjb

git ls-tree -r HEAD

I tried searching for how to list the files in a revision in git, and found only how to list the changed files in a revision.

I knew that gitk shows a list of files and directories in any given repo. So I looked in it (it’s a wish script) to find out how it gets the list of files for each revision. Found it around 3/4 of the way down, in proc gettree.

Probably most anything you’d want to do with git, you can find it in gitk.

Categories: , , ,
Posted by: bjb

I’ll be giving a talk tonight at OPAG called “Enough git for julython”. That’s right, julython is coming up in a few days. I want to help boost the Ottawa, Canada participation by removing a possible barrier to participation: I will be showing people how to use git and github.

Julython is basically an informal contest that encourages people to write some python code and check it in publicly into github or bitbucket.

The talk is at Shopify tonight, Thursday June 27, at 19:30.

Categories: , ,
Posted by: bjb
My co-worker encouraged me to post this ….

Our nightly builds started failing a while ago, and we wanted to know why. Nothing was immediately obvious so, as a new member to the team, I wanted to see what was different between “day that it worked” and “day that it failed”. Or rather, as the builds fixed themselves after a few days, what was the difference between “day that it failed” and “day that it worked”.

Well the android build is made up of a bunch of subprojects, each with its own git repository. I wasn’t going to be cd into each directory and running “git log” to see if something changed there lately. So I learned about the “forall” subcommand in repo:
repo forall -c "pwd; git log | grep '^[dD]ate' | head -1" > /tmp/repo-last-update-16 
and again in the other build directory.

A little massaging of the outputs allowed me to compare them with diff and find a differing project.