8000 Feat: Add Access Token Authentication for Private Repositories by TheRealTimo · Pull Request #257 · cyclotruc/gitingest · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Feat: Add Access Token Authentication for Private Repositories #257

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’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 5 commits into
base: main
Choose a base branch
from

Conversation

TheRealTimo
Copy link

This PR adds support for cloning private repositories using a Personal Access Token (PAT) via the new --access-token CLI option or the "Access Token" field in the Web UI.

Key Changes:

  • Implemented generic token handling for GitHub, GitLab, Codeberg, and Bitbucket by detecting the host and constructing the appropriate HTTPS auth URL.
  • The token is used only during the clone operation, is never stored or logged, and is redacted ([REDACTED]) in server output.
  • Fixed Web UI bugs related to form submission and dynamic content updates (git_form.jinja, utils.js).
  • Improved user-facing error messages in the Web UI for common cloning failures (auth errors, not found, timeout).
  • Updated README.md with instructions for using the --access-token option.
  • Added unit tests covering token handling, multi-host support, and security checks. All tests pass (82/82).
  • Passed all pre-commit checks (Black, isort, Pylint, etc.).
    This enhancement allows gitingest to securely access private repositories on major Git platforms.

This PR addresses issue #246.

Copy link
Collaborator
@filipchristiansen filipchristiansen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There seems to be quite a few changes in this PR that are unrelated to the proposed feature. Please commit only changes related to the feature.

Copilot

This comment was marked as resolved.

Copy link
@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot reviewed 11 out of 13 changed files in this pull request and generated no comments.

Files not reviewed (2)
  • requirements-dev.txt: Language not supported
  • src/server/templates/components/git_form.jinja: Language not supported

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants
0