Skip to content

eslint/eslint-github-bot

Folders and files

NameName
Last commit message
Last commit date
Jan 15, 2025
Sep 12, 2023
Jan 20, 2025
Jan 15, 2025
Jun 25, 2017
Jan 16, 2025
Aug 3, 2018
Sep 23, 2018
Jul 7, 2017
Jan 9, 2023
Jan 16, 2025
Jan 20, 2025
Jan 20, 2025
Jan 20, 2025

Repository files navigation

Build Status

ESLint GitHub bot

eslint-github-bot is a bot created with probot which automates some common tasks for repositories run by the ESLint team.

Environment Variables:

  • APP_ID (required): The numeric GitHub app ID
  • PRIVATE_KEY (required): the contents of the private key you downloaded after creating the app.
  • WEBHOOK_SECRET (required): Secret setup for GitHub webhook or you generated when you created the app.
  • PORT: Port for web server (optional, defaults to 8000).

🔧 Setup

  • Clone this repo
  • npm install
  • npm test

To start the server locally, you'll need:

  • A PEM file
  • A .env file that specifies the required environment variables

The APP_ID and WEBHOOK_SECRET need to be present but need not be the registered application ID or webhook secret to start the server. PRIVATE_KEY must be a valid PEM private key.

Adding plugins

To add a plugin:

  1. Create the plugin as a new file in src/plugins.
  2. Add the plugin to the list in src/plugins/index.js.
  3. Add the plugin to the list in src/app.js to enable it by default.

Deployment

The bot is deployed to a Dokku instance named https://github-bot.eslint.org and is installed as a GitHub Application at the organization level.

The URL to receive webhooks is the default for Probot, which is /api/github/webhooks. This must be configured for the app on the ESLint organization.

Health Check

https://github-bot.eslint.org/ping