Skip to content
/ ghit Public

Command-line toolkit that blends hand-crafted workflows with OpenAPI-generated commands for GitHub.

License

Notifications You must be signed in to change notification settings

toneflix/ghit

Repository files navigation

Ghit

NPM Downloads npm version License CI Deploy Docs

Command-line toolkit for GitHub: authenticate once, set a repo, and work with issues in bulk or interactively. Includes a generator that syncs the CLI surface with the GitHub OpenAPI spec.

Install

pnpm add -g ghit
# or npm i -g ghit

Quick start

  • Login: ghit login (opens browser flow, stores token locally)
  • Set default repo: ghit set-repo owner/name
  • Inspect info: ghit info
  • Work with issues (interactive): ghit issues to list, view, close/reopen, edit, or delete
  • Seed/update/delete issues in bulk: ghit issues:seed, ghit issues:update, ghit issues:delete

Generated API commands (dynamic)

The CLI can generate commands directly from the GitHub OpenAPI spec. This keeps available commands and params in sync with GitHub without hand-coding.

  1. Generate commands (writes .ghit/apis.generated.js):
    ghit generate:apis
  2. Use generated commands (examples):
    • Create issue: ghit issues:create --title "Bug" --owner org --repo repo
    • List issues: ghit issues:list-for-repo --owner org --repo repo
    • Get single issue: ghit issues:get --owner org --repo repo --issue_number 123

Notes

  • The generator runs once and the CLI will auto-load .ghit/apis.generated.js on subsequent runs.
  • Only the command usage matters; you do not need to edit the generated file by hand.

Contributing

Contributing

Contributions are welcome! Please follow these steps:

  1. Fork the repository
  2. Create a feature branch (git checkout -b feature/amazing-feature)
  3. Commit your changes (git commit -m 'Add amazing feature')
  4. Push to the branch (git push origin feature/amazing-feature)
  5. Open a Pull Request

Development Guidelines

  • Write TypeScript with proper type definitions
  • Follow existing code style
  • Add tests for new features
  • Update documentation for API changes
  • Ensure all tests pass before submitting PR

License

This project is licensed under the ISC License - see the LICENSE file for details.

Support

Acknowledgments


© Copyright 2026 - ToneFlix Technologies Limited

About

Command-line toolkit that blends hand-crafted workflows with OpenAPI-generated commands for GitHub.

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors