Skip to content

Enable .github/osschat.yml to store OSSChat configuration for consumer repos #179

@huan

Description

@huan

By default, this plugin loads configuration from a given repository file. If the file doesn't exist, it loads configuration from the same path in the same owner's .github repository.
https://github.com/probot/octokit-plugin-config

// given that `.github/my-app.yml` in `octocat/hello-world` has the following ocntent
//
// comment: 'Thank you for creating the issue!'
//
const { config } = await octokit.config.get({
  owner: "octocat",
  repo: "hello-world",
  path: ".github/my-app.yml",
});
// config is now { comment: "Thank you for creating the issue!" }

// all options and returns
const { config, files } = await octokit.config.get({
  owner: "octocat",
  repo: "hello-world",
  path: ".github/my-app.yml",
  defaults: {
    comment: "Thank you for creating the issue!",
  },
  branch: "develop",
});
// files is an array of { owner, repo, path, config } objects

We can design a .github/osschat.yml for our osschat users to store their settings in this file so that osschat can be easier to be configured.

OSSChat .github/osschat.yml Proposal

chatops:
  room:
    - 12341234@chatroom
chatopera:
  faq: ./faq.yaml
  admins:
    - huan
    - mingyu

The above is a demo for this idea

See also: https://probot.github.io/api/latest/classes/context.html#config

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions