{"id":19177749,"url":"https://github.com/jessety/github-webhook","last_synced_at":"2025-07-14T03:40:58.780Z","repository":{"id":77098749,"uuid":"284271293","full_name":"jessety/github-webhook","owner":"jessety","description":"A minimal GitHub webhook listener that executes a specified command when push occurs on the default branch, or when a release is published.","archived":false,"fork":false,"pushed_at":"2020-08-21T19:38:32.000Z","size":69,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-01-04T02:48:42.966Z","etag":null,"topics":["github-webhook","github-webhook-handler","github-webhook-listener"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/jessety.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2020-08-01T14:03:41.000Z","updated_at":"2020-09-06T18:57:00.000Z","dependencies_parsed_at":null,"dependency_job_id":"68cd694d-487b-4c7e-9248-6c8fc32ae7bf","html_url":"https://github.com/jessety/github-webhook","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jessety%2Fgithub-webhook","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jessety%2Fgithub-webhook/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jessety%2Fgithub-webhook/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jessety%2Fgithub-webhook/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jessety","download_url":"https://codeload.github.com/jessety/github-webhook/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":240254568,"owners_count":19772439,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["github-webhook","github-webhook-handler","github-webhook-listener"],"created_at":"2024-11-09T10:34:56.835Z","updated_at":"2025-02-23T01:19:14.223Z","avatar_url":"https://github.com/jessety.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# github-webhook\n\nA minimal GitHub webhook listener that executes a script when a push event occurs on the default branch, or when a release is published.\n\n[![ci](https://github.com/jessety/github-webhook/workflows/ci/badge.svg)](https://github.com/jessety/github-webhook/actions)\n\n## Installation\n\n```bash\ngit clone ...\ncd github-webhook\n\nnpm install --production\npm2 start ecosystem.config.json\n```\n\n## Configuration\n\nPopulate an `.env` file in the project directory with the following options:\n\n```ini\n# GitHub Webhook Secret (required)\nSECRET=ABC123\n\n# Script to execute when a release is published\nSCRIPT_RELEASE=/usr/local/bin/release.sh\n\n# Script to execute when there is a push to the default branch\nSCRIPT_PUSH=/usr/local/bin/push.sh\n\n# Name of the default branch, if it isn't \"main\" or \"master\"\nDEFAULT_BRANCH=primary\n\n# Port to run the server on\nPORT=32490\n```\n\n## Scripts\n\nScripts are executed with the name of the repository as the first parameter, and the event type as the second.\n\nPush events are only triggered when a push is made to the default branch. The script is executed with the name of that branch as its third parameter. Given the above configuration, the following will be executed a push is made to the `primary` branch:\n\n```bash\n/usr/local/bin/push.sh jessety/github-webhook push primary\n```\n\nWhen a release is triggered, the release tag is sent as a third parameter:\n\n```bash\n/usr/local/bin/release.sh jessety/github-webhook release v1.1.4\n```\n\n## License\n\nMIT © Jesse Youngblood\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjessety%2Fgithub-webhook","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjessety%2Fgithub-webhook","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjessety%2Fgithub-webhook/lists"}