Sign-in: add GitHub as a sign-in method

Đang mở
#109 0 bình luận 0 reaction 0 người được giao Xem trên GitHub

Chưa có ai nhận issue này.

Đánh giá

Độ khó
3/5
Thời gian dự kiến
1-2 ngày
Mức phù hợp với người mới
50/100
Loại issue
Tính năng
Độ rõ ràng
Đặc tả rõ ràng
Mức độ hoạt động
Sôi nổi
Công nghệ
github, typescript

Hướng nghiên cứu

Start in lib/auth/providers.ts and follow how the Google entry is listed and wired into the auth configuration and sign-in action. Add a GitHub entry that is shown only when its client ID and secret are set, then update the example env file and the self-hosting docs under content/docs/. Done when the provider, action and login-form tests cover GitHub, an unconfigured provider id is rejected, and pnpm test and pnpm build pass.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

backend enhancement frontend

Copied from DeadantCo/answerLoops#99 · originally opened by sethr07 on 2026-11-20

Copied from https://github.com/answerLoops/answerLoops/issues/455 — originally opened by @NathanTarbert on 2026-10-23

Problem

The sign-in page now reads its methods from the list in lib/auth/providers.ts (shipped in #371), but Google is the only entry. Developers and many self-hosters expect to sign in with GitHub, and people without a Google account cannot sign in at all.

Scope

  • Add a github entry to the provider list in lib/auth/providers.ts, listed only when its client ID and secret are set, so installs without them see no dead button.
  • Register the matching provider in the auth configuration and make sure new users go through the same account provisioning as the Google path.
  • Carry plan, billing period, promo code and the post-login destination through exactly as the Google path does.
  • Add the new environment variables to the example env file and the self-hosting docs under content/docs/, with a short setup walkthrough.
  • Cover the new entry in the existing provider, action and login-form tests.

Acceptance criteria

  • A GitHub button appears on /login only when its credentials are set, and signing in creates or finds the right user and organization.
  • Plan, interval, promo code and redirect survive the GitHub sign-in.
  • An unlisted or unconfigured provider id is rejected by the sign-in action.
  • Docs and the example env file describe the new variables.
  • pnpm test and pnpm build pass.

Related: #370, #371

Start here: new to the project? Read CONTRIBUTING.md first. It covers the ground rules, running answerLoops locally, and how to open a pull request.

Ngôn ngữ chính
TypeScript
Star
0
Fork
0
Chỉ số merge pull request
Không có pull request nào được merge trong 30 ngày

Chuẩn bị môi trường

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của DeadantCo/answerLoopsdev

Tất cả issue của DeadantCo/answerLoopsdev

Issue tương tự

Thêm issue về TypeScript

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.