Skip to content

Add Pyproject.toml - #63

Closed
mandylan75 wants to merge 7 commits into
mainfrom
feature/issue-46/pyproject
Closed

Add Pyproject.toml#63
mandylan75 wants to merge 7 commits into
mainfrom
feature/issue-46/pyproject

Conversation

@mandylan75

Copy link
Copy Markdown
Contributor

#46

@mandylan75
mandylan75 requested a review from egrace479 July 1, 2026 19:18

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Refactors the repository into an installable Python package (src/repo_exporter) and introduces a CLI entry point to export GitHub or Hugging Face org/repo metadata into Google Sheets, aligning with Issue #46’s “pyprojectify” goal.

Changes:

  • Adds a shared BaseExporter with common Google Sheets write/format utilities and run orchestration.
  • Introduces platform-specific exporters for GitHub and Hugging Face under src/repo_exporter/.
  • Adds a package CLI (python -m repo_exporter / console script) and a pyproject.toml for packaging.

Reviewed changes

Copilot reviewed 7 out of 7 changed files in this pull request and generated 6 comments.

Show a summary per file
File Description
src/repo_exporter/base.py New abstract base class + shared Sheets utilities + common run() orchestration.
src/repo_exporter/github.py New GitHub exporter implementation for metadata extraction + Sheets update.
src/repo_exporter/huggingface.py New Hugging Face exporter implementation for metadata extraction + Sheets update.
src/repo_exporter/main.py New CLI entrypoint to run either exporter based on CLI args/env.
src/repo_exporter/init.py Exposes package exports (__version__, exporters).
src/repo_exporter/about.py Defines package version.
pyproject.toml Defines build system, dependencies, versioning, and console scripts.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread pyproject.toml Outdated
Comment thread pyproject.toml Outdated
Comment thread pyproject.toml
Comment on lines +127 to +132
try:
if repo.get_readme():
return "Yes"
except GithubException:
return "No"

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Though I'd probably put return "No" before the except line (similarly for the license check).

Comment on lines +141 to +146
try:
if repo.get_license():
return "Yes"
except GithubException:
return "No"

Comment on lines +188 to +197
try:
for key in keys:
value = repo.card_data.get(key, "")
if value:
if isinstance(value, list):
return ", ".join(str(v) for v in value)
return str(value)
except Exception:
return "N/A"

Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
@mandylan75 mandylan75 changed the title Feature/issue 46/pyproject Add Pyproject.toml Jul 2, 2026

@egrace479 egrace479 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I just realized that I never submitted this review. You can take the feedback for the pyproject.toml and just add it to #62.

Comment thread pyproject.toml Outdated
Comment thread pyproject.toml Outdated
Comment thread pyproject.toml Outdated
Comment thread pyproject.toml
Comment thread pyproject.toml Outdated
Comment on lines +127 to +132
try:
if repo.get_readme():
return "Yes"
except GithubException:
return "No"

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Though I'd probably put return "No" before the except line (similarly for the license check).

mandylan75 and others added 2 commits July 7, 2026 15:47
Co-authored-by: Elizabeth Campolongo <38985481+egrace479@users.noreply.github.com>
@egrace479

Copy link
Copy Markdown
Member

Changes incorporated into #62.

@egrace479 egrace479 closed this Jul 7, 2026
@mandylan75
mandylan75 deleted the feature/issue-46/pyproject branch July 7, 2026 21:52
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.

3 participants