Skip to main content

Interactive Git history management and commit inspection tools with comprehensive diff review

Project description

Gitship 🚀

Git on Autopilot. Stop plumbing, start shipping.

gitship is a high-level workflow manager that wraps Git in a layer of intelligence and safety. It doesn't just run Git commands; it orchestrates your entire development lifecycle—from the first line of code to the final PyPI release.

PyPI version License: MIT Python 3.8+


💡 Why Gitship?

Most developers treat Git as a plumbing tool. Gitship treats Git as an architect.

  • Atomic Operations: Never see a "dirty tree" error again. Gitship automatically stashes and restores background noise (like translation files or build artifacts) during branch switches and merges.
  • Semantic History: Your git log shouldn't be a mystery. Gitship generates data-driven commit and merge messages that categorize changes into Features, Fixes, and Stats.
  • Safety-First Workflows: Rebase-by-default syncing, interactive conflict resolution with state-caching, and identity-verified publishing.

🛠 Features

🛡️ Atomic GitOps (The "Safe-State" Engine)

Gitship uses a unique Atomic Engine to ensure your repository stays clean:

  • Intelligent Stashing: Automatically stashes and restores ignorable background changes (like AI-generated translations or config updates) during critical operations.
  • Conflict Caching: If a merge fails, Gitship caches your resolutions, allowing you to abort, fix, and resume without losing work.

🧠 Intelligent Commits & Amends

  • Category Awareness: Changes are analyzed and grouped (Code, Translations, Tests, etc.).
  • Smart Amending: Rewrite your last commit message with automated analysis of what actually changed.
  • Rename Detection: Content-based similarity detection even when standard Git fails to see a move.
  • Condensed Exports: Export diffs with 60-70% size reduction using --unified=1 for easier code review.

🌿 Advanced Branch & Sync

  • Unified Sync: gitship sync performs a safe pull (rebase) and push in one atomic operation.
  • Directional Review: Compare any two branches with a visual "Incoming Changes" vs "Target Status" report.
  • Bulk Cleanup: Identify and delete redundant, merged, or stale remote branches in seconds.
  • Interactive Merging: Guided merge workflows with conflict resolution caching.

📦 Dependency & Project Management

  • AST-Based Scanner: Detects imports in your source code and maps them to PyPI packages.
  • Permanent Ignores: Maintain a project-specific list of packages you never want to track in pyproject.toml.
  • README Editor: Section-by-section interactive README editor with auto-centering for badges.
  • Gitignore Manager: Add/remove patterns from .gitignore via CLI with common language templates.

⚓ Professional Releases

  • Semantic Versioning: Guided patch/minor/major bumping.
  • OIDC / Trusted Publishing: Automated PyPI release configuration.
  • Draft GitHub Releases: Auto-generates high-quality release notes from categorized commit history.

🚀 Quick Start

Installation

pip install gitship

The "Daily Flow" Commands

Command Action
gitship The Dashboard: Interactive menu for all operations.
gitship sync Pull (rebase), resolve conflicts, and push in one go.
gitship commit Analyze changes and commit with a smart message.
gitship branch Manage, compare, and merge branches safely.
gitship deps Sync pyproject.toml with your actual imports.
gitship release Bump version, generate changelog, and ship to PyPI/GitHub.
gitship amend Smart commit message rewriting with merge analysis.
gitship ignore Manage .gitignore entries from CLI.
gitship docs Interactive section-by-section README editor.
gitship resolve Interactive conflict resolver with block-by-block choices.

🔧 Advanced Usage

Interactive Conflict Resolution

If a merge or pull hits a conflict, Gitship enters Resolve Mode:

gitship resolve

It provides a block-by-block interactive UI, allowing you to choose "Ours", "Theirs", or "Manual" for every conflict hunk, and caches your progress if you need to step away.

Condensed Code Reviews

Export a massive diff into a readable, minimal-context review file:

gitship commit  # Choose option 2 to review code changes
                # Then option 4 to export diff
                # Select condensed format (60-70% smaller)

Uses --unified=1 and strips noise to reduce diff size dramatically.

Atomic Operations Under the Hood

Gitship's gitops.py module wraps critical Git operations (push, pull, merge, checkout) with automatic stashing/restoring:

from gitship.gitops import atomic_git_operation

# Automatically handles background file changes
atomic_git_operation(
    repo_path=repo,
    git_command=["push", "origin", "main"],
    description="push to origin/main"
)

📚 Documentation

Full documentation and guides coming soon. For now, explore interactively:

gitship  # Main menu with all features

🤝 Contributing

Gitship is built by developers who are tired of Git overhead. If you have an idea to make Git "just work," we want your PRs!

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

📄 License

MIT License 1minds3t

See LICENSE for details.


🙏 Acknowledgments

Built with:

  • Python 3.8+
  • Rich for beautiful terminal output
  • Typer for CLI magic
  • Omnipkg for advanced dependency resolution (optional)

Stop fighting Git. Start shipping code.

Install NowReport BugRequest Feature

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

gitship-0.3.1.tar.gz (151.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

gitship-0.3.1-py3-none-any.whl (153.4 kB view details)

Uploaded Python 3

File details

Details for the file gitship-0.3.1.tar.gz.

File metadata

  • Download URL: gitship-0.3.1.tar.gz
  • Upload date:
  • Size: 151.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for gitship-0.3.1.tar.gz
Algorithm Hash digest
SHA256 352d2bb7965b8e3b4a868b50e3b36f121b8d66e917f9444aa744e72bbac2a1d3
MD5 761301b433d2530aba30298e89b3acc1
BLAKE2b-256 f5c3341d19b276f3e14802ea6555b2c545c4e13b350b1069e02ce2a1a6e9aa7e

See more details on using hashes here.

Provenance

The following attestation bundles were made for gitship-0.3.1.tar.gz:

Publisher: publish.yml on 1minds3t/gitship

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file gitship-0.3.1-py3-none-any.whl.

File metadata

  • Download URL: gitship-0.3.1-py3-none-any.whl
  • Upload date:
  • Size: 153.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for gitship-0.3.1-py3-none-any.whl
Algorithm Hash digest
SHA256 73e4f00c05b394a5d9959a87f0e2ba869794a0ac32d4421d0a025545607762fb
MD5 62fff19583b9b6e1f4bf4aa47ff72082
BLAKE2b-256 a89aeb4d7a732ecd81ab055f486c46d42b86901b70980ee39237f458fc5dbfe6

See more details on using hashes here.

Provenance

The following attestation bundles were made for gitship-0.3.1-py3-none-any.whl:

Publisher: publish.yml on 1minds3t/gitship

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page