PackagistとGitHubをWebHookで自動連携設定

Packagist側でAPIトークンを発行する20桁の16進数
(Profile のYour API Token)

Payload URL
https://packagist.org/api/github?username=berdysh-dev

ログインした状態で公式ドキュメントを確認すると表示される
https://packagist.org/about#how-to-update-packages

GitHub側でログインする

右上のSettings -> 左側メニューのWebHooks -> 右上のAdd webhook

Payload URL

Packagist側で発行した https://packagist.org/api/github?username=ユーザ名

Content type
application/json

Secret
APIトークン？

Update webhook で保存する

Settings -> Recent Deliveries


{"status":"error","message":"Could not find a package that matches this request (does user maintain the package?)"}

The package name berdysh-dev/HelloComposer is invalid, it should not contain uppercase characters. We suggest using berdysh-dev/hello-composer instead.

大文字は使えないので HelloComposer を hello-composer に変更

https://packagist.org/packages/submit

Repository URL (Git/Svn/Hg)
https://github.com/berdysh-dev/hello-composer
Check -> Submit

This package is not auto-updated. Please set up the GitHub Hook for Packagist so that it gets updated whenever you push!

Git Hub側 の Recent Deliveries で [redelivery] を再実行して Response 202

{"status":"success","jobs":["**********"],"type":"github_auto"}

更新後のバージョン確認

GitHub側でリリース操作をしないと、Composer側が更新されない

Tags 付け

git tag -a v1.0.16 -m 'version 1.0.16'
