Having such serious asthma attacks that I need to stay and work from home gave me more time on my hands in front of the computer and one night I decided to try git again.
When I tried out the famous git tutorial, it didn't really help me understand how to really use it for what I wanted - a centralized repo for all my stuff, so I googled for a long while and still didn't really get anywhere. I went to the git chatroom and in 5 minutes got a bare git repo initiated, moved a few projects and started developing synchronously from 3 different places.
Basically, this is what I had to do:
At least, that's what I think I did.
Anyway, a few things worth mentioning about git (for those that don't know it too well):
I know there must be many things that I'm not mentioning that other git veterans know, such as advanced merging, multiple remote repos and stuff I probably don't know about.
Reasons to put your code in a repository:
More thoughts I feel like throwing in:
I don't actually write the Changes file directly from git, but I find this command rather helpful when preparing a new release:
git --no-pager log --no-merges --pretty=format:' %x20%x20 - %s (%an)' `git tag | tail -n 1`..
Which prints the summary of all changes since the last release (= last git tag). In fact I added this (and a few variations) to my
[alias]
lastchanges =!git --no-pager log --no-merges --pretty=format:' %x20%x20 - %s (%an)' `git tag | tail -n 1`..
Re:writing changes files from git
mpeters on 2009-04-13T14:22:49
neat tip, thanks domm!
Re:writing changes files from git
xsawyerx on 2009-04-13T15:26:52
Nifty stuff, thanks!
After reading your comment, I wrote a simple script to convert the `git --no-pager log --no-merges` to a well structured Changes file. The only problem was that you can't figure the version of the file each time. However, if one will add a check in the script to see when a certain file's $VERSION had changed, one would be able to output a well structured Changes file from git history. Sounds like an idea for a module, really. Maybe I'll sit and write it some day.
For some reason the formatting didn't work for me, and I'm not using any tags yet, but it's really cool to learn new things. I didn't know about --no-merges and --no-pager. Thanks again.
Hi Folks
Check out:
http://use.perl.org/user/jdavidb/journal/36220
Cheers
Re:And from use Perl's very own journal system...
xsawyerx on 2009-04-13T22:47:55
I'll start going over them as soon as I can. Thanks for sharing!