Skip to content

All-contributors Github Bot does not recognise "custom types" for contributions (CLI does) #505

Open
@JesperDramsch

Description

Describe the bug
The all-contributors bot does not work on custom types.

To Reproduce
Steps to reproduce the behavior:

  1. Use the example from the docs:
{
  "projectName": "all-contributors",
  "projectOwner": "all-contributors",
  "repoType": "github",
  "repoHost": "https://github.com",
  "files": ["README.md"],
  "imageSize": 100,
  "commit": false,
  "contributorsPerLine": 7,
  "contributorsSortAlphabetically": false,
  "badgeTemplate": "[![All Contributors](https://img.shields.io/github/all-contributors/<%= projectOwner %>/<%= projectName %>?color=ee8449&style=flat-square)](#contributors)",
  "contributorTemplate": "<a href=\"<%= contributor.profile %>\"><img src=\"<%= contributor.avatar_url %>\" width=\"<%= options.imageSize %>px;\" alt=\"\"/><br /><sub><b><%= contributor.name %></b></sub></a>",
  "wrapperTemplate": "\n<table>\n  <tbody><%= bodyContent %>  </tbody>\n<%= tableFooterContent %></table>\n\n",
  "types": {
    "custom": {
      "symbol": "🔭",
      "description": "A custom contribution type.",
      "link": "[<%= symbol %>](<%= url %> \"<%= description %>\"),"
    }
  },
  "linkToUsage": true,
  "skipCi": true,
  "contributors": []
}
  1. Comment @all-contributors please add @<username> for custom.
  2. Get a confused bot comment

I couldn't determine any contributions to add, did you specify any contributions?
Please make sure to use valid contribution names.

Expected behavior
A clear and concise description of what you expected to happen.

It should work with custom types, as the CLI does.

Screenshots
If applicable, add screenshots to help explain your problem.

Made a quick example here: JesperDramsch/python-deadlines#53

Image

The config has this entry and works with CI:

{
...
"types": {
    "conference": {
      "symbol": "📆",
      "description": "Python conference (Added or updated)",
      "link": "#conference-<%= contributor.login %>"
    }
  },
...
}

Additional context
Add any other context about the problem here.

It works using the CLI, so I assume my config is alright. I have made the quick example with myself as to avoid pings. It has not worked on other accounts as well.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions