Skip to content

Add JSON output mode#46

Open
mawxcodehub wants to merge 1 commit into
promptpolish-ai:mainfrom
mawxcodehub:feature/json-output
Open

Add JSON output mode#46
mawxcodehub wants to merge 1 commit into
promptpolish-ai:mainfrom
mawxcodehub:feature/json-output

Conversation

@mawxcodehub

Copy link
Copy Markdown

Summary

  • adds a --json flag that emits the same repository context as structured JSON
  • keeps the existing Markdown output as the default behavior
  • documents the new flag in the README and usage guide
  • sets stdout to UTF-8 so Unicode tree output works reliably on Windows consoles

Verification

  • python git-context --json --log 1 | python -m json.tool
  • python -m git_context --json --log 0 | python -m json.tool
  • python git-context --log 1

Closes #2.

@mawxcodehub

Copy link
Copy Markdown
Author

Ready for review. Payout address for #2 if accepted: 0x30cE495ea6fE4C7d8Ad7D8c576EcAE8e4f900A92 (EVM compatible: Ethereum/Base/Polygon/BSC).

@mawxcodehub mawxcodehub force-pushed the feature/json-output branch from 8390cc7 to a401418 Compare June 10, 2026 10:34
@mawxcodehub

Copy link
Copy Markdown
Author

Updated the PR with focused unittest coverage for the new JSON mode. Current local verification:

  • python -m unittest discover -v
  • python -m git_context --dir . --json --log 1 | python -m json.tool
  • python -m git_context --dir . --json --files --log 0 | python -m json.tool

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.

Add --json output mode (Bounty: $2 crypto)

1 participant