Dist::Zilla::Plugin::Twitter - Twitter when you release with Dist::Zilla
version 0.009
In your dist.ini:
dist.ini
[Twitter] hash_tags = #foo
In your .netrc:
.netrc
machine api.twitter.com login YOUR_TWITTER_USER_NAME password YOUR_TWITTER_PASSWORD
This plugin will use Net::Twitter with the login and password in your .netrc file to send a release notice to Twitter. By default, it will include a link to your README file as extracted on a fast CPAN mirror. This works very nicely with Dist::Zilla::Plugin::ReadmeFromPod.
The default configuration is as follows:
[Twitter] tweet_url = http://cpan.cpantesters.org/authors/id/{{$AUTHOR_PATH}}/{{$DIST}}-{{$VERSION}}.readme tweet = Released {{$DIST}}-{{$VERSION}} {{$URL}}
The tweet_url is shortened with WWW::Shorten::TinyURL and appended to the tweet messsage. The following variables are available for substitution in the URL and message templates:
tweet_url
tweet
DIST # Foo-Bar VERSION # 1.23 TARBALL # Foo-Bar-1.23.tar.gz AUTHOR_UC # JOHNDOE AUTHOR_LC # johndoe AUTHOR_PATH # J/JO/JOHNDOE URL # TinyURL
You must be using the UploadToCPAN or FakeRelease plugin for this plugin to determine your CPAN author ID.
UploadToCPAN
FakeRelease
You can use the hash_tags option to append hash tags (or anything, really) to the end of the message generated from tweet.
hash_tags
[Twitter] hash-tags = #perl #cpan #foo
David Golden <dagolden@cpan.org>
This software is Copyright (c) 2010 by David Golden.
This is free software, licensed under:
The Apache License, Version 2.0, January 2004
To install Dist::Zilla::Plugin::Twitter, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Dist::Zilla::Plugin::Twitter
CPAN shell
perl -MCPAN -e shell install Dist::Zilla::Plugin::Twitter
For more information on module installation, please visit the detailed CPAN module installation guide.