Dist::Zilla::Plugin::Git::PushInitial - do initial git push from your minting profile
In your profile.ini:
[Git::Init] [GitHub::Create] repo = {{ lc $dist->name }} prompt = 1 [Git::PushInitial] remote = origin # default
This module is only of interest to authors of Dist::Zilla minting profiles.
After minting a new dist with Git::Init and setting remote information with e.g. GitHub::Create, if push.default is not configured or set at the default value (tracking), or an older git is being used, it is necessary to create the branch on the remote before a simple git push, done by e.g. Git::Push will work on dzil release.
push.default
tracking
git push
dzil release
Using this plugin in your minting profile should save the users of your minting profile the step of doing a manual push, regardless of their git config. They can just commit and do a dzil release, assuming they are using Git::Push in their dist.ini.
It runs this command:
git push <remote> <current-branch>
remote defaults to 'origin' but can be specified as a parameter to this plugin.
The remote to push to, default is origin.
origin
Minting Profiles Tutorial
Dist::Zilla::Plugin::Git::Init
Dist::Zilla::Plugin::GitHub::Create
Dist::Zilla::Plugin::Git::Push
Dist::Zilla::MintingProfile::Author::Caelum
Some code/ideas stolen from Alessandro Ghedini's Dist::Zilla::Plugin::GitHub::Create.
Rafael Kitover <rkitover@cpan.org>
To install Dist::Zilla::Plugin::Git::PushInitial, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Dist::Zilla::Plugin::Git::PushInitial
CPAN shell
perl -MCPAN -e shell install Dist::Zilla::Plugin::Git::PushInitial
For more information on module installation, please visit the detailed CPAN module installation guide.