mbleigh (owner)

Revisions

gist: 26189 Download_button fork
public
Public Clone URL: git://gist.github.com/26189.git
Embed All Files: show embed
Perl #
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
#!/usr/bin/perl
 
# Present.ly Post-Commit Hook for Git
# change your subdomain, username and password, then copy this file as .git/hooks/post-commit
# then 'chmod +x .git/hooks/post-commit'
# it'll run every time you commit (not push, mind you)
 
$project='Project Name'
$subdomain='yoursubdomain'
$username='username';
$password='password';
 
$git_text = `git log -n1 --pretty=format:"[$project] (%h) %s"`;
chomp $git_text;
`curl "https://$subdomain.presentlyapp.com/api/twitter/statuses/update.xml" -u $username:$password -d status="$git_text"`;