Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

馃殌 Feature: Setup script should add the running user to .all-contributorsrc #156

Closed
3 tasks done
JoshuaKGoldberg opened this issue Dec 24, 2022 · 0 comments 路 Fixed by #407
Closed
3 tasks done
Labels
good first issue Good for newcomers, please hop on! status: accepting prs Please, send a pull request to resolve this! type: feature New enhancement or request

Comments

@JoshuaKGoldberg
Copy link
Owner

Bug Report Checklist

  • I have tried restarting my IDE and the issue persists.
  • I have pulled the latest main branch of the repository.
  • I have searched for related issues and found none that matched my issue.

Overview

From #147: if someone is running the setup script, they should be added to the .all-contributorsrc allcontributors config for (I'm thinking to start): code, content, documentation, ideas, infrastructure, maintenance, projectManagement, tool.

Additional Info

See https://allcontributors.org/docs/en/emoji-key for the full allcontributors emoji key.

The setup script already makes sure the user is authenticated with gh. So you can get information on the user by running gh api user in the script.

const user = JSON.parse(await $`gh api user`);
@JoshuaKGoldberg JoshuaKGoldberg added good first issue Good for newcomers, please hop on! type: feature New enhancement or request status: accepting prs Please, send a pull request to resolve this! labels Dec 24, 2022
JoshuaKGoldberg pushed a commit that referenced this issue May 8, 2023
<!-- 馃憢 Hi, thanks for sending a PR to template-typescript-node-package!
馃挅.
Please fill out all fields below and make sure each item is true and [x]
checked.
Otherwise we may not be able to review your PR. -->

## PR Checklist

- [x] Addresses an existing open issue: fixes #156
- [x] That issue was marked as [`status: accepting
prs`](https://github.com/JoshuaKGoldberg/template-typescript-node-package/issues?q=is%3Aopen+is%3Aissue+label%3A%22status%3A+accepting+prs%22)
- [x] Steps in
[CONTRIBUTING.md](https://github.com/JoshuaKGoldberg/template-typescript-node-package/blob/main/.github/CONTRIBUTING.md)
were taken

## Overview

I added some logic to add the running user to the `all-contributors`
list (according to the authenticated GitHub CLI account).
At first, I tried only to use the owner variable that the user prompted,
but it failed the tests, where a fabricated owner name was provided; if
you prefer to only use the provided owner name without reaching out to
gh CLI, we might need to adjust the tests a little bit.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers, please hop on! status: accepting prs Please, send a pull request to resolve this! type: feature New enhancement or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant