Skip to content
Back to home
Back to blog
Feature

Version Control: Git Built into PocketCode

Master Git without leaving the editor. Commits, branches, merge, stash and more with full Git integration in PocketCode.

3 min
By Pelayo Naredo
Version Control: Git Built into PocketCode

Version Control: Git Built into PocketCode

Git is fundamental in modern development. PocketCode integrates Git natively so you can manage your code without needing the integrated terminal.

Visual Git interface

Changes panel

The Git side panel shows in real-time:

  • Modified files (M) — Pending changes
  • New files (U) — Untracked
  • Deleted files (D) — Removed
  • Conflicts (C) — Require manual resolution

Visual diff

Tap any modified file to see differences side by side:

  • Added lines in green
  • Deleted lines in red
  • Inline changes highlighted

Basic operations

Making a commit

# From the visual interface:
# 1. Select files in the changes panel
# 2. Write the commit message
# 3. Tap "Commit"

# Or from the integrated terminal:
git add .
git commit -m "feat: add authentication system"

Working with branches

Create and switch branches easily:

# Create new branch
git checkout -b feature/new-feature

# List branches
git branch -a

# Switch branch
git checkout main

# Delete branch
git branch -d feature/completed

Merge and rebase

PocketCode offers visual conflict resolution:

  1. Start the merge from the Git panel
  2. If there are conflicts, the resolution editor opens
  3. Choose between changes from each branch
  4. Confirm the resolution

Workflows

Git Flow

main ─────────────────────── production
  └── develop ─────────────── development
        ├── feature/login ──── feature
        ├── feature/api ────── feature
        └── hotfix/bug-123 ── urgent fix

Trunk-Based Development

main ─────────────────────── single main branch
  ├── short-lived-branch ──── short-lived (< 1 day)
  └── feature-flag ────────── hidden feature

Platform integration

GitHub

  • Direct Push/Pull
  • Pull Requests from the app
  • Issues linked to commits
  • Actions status visible

GitLab

  • Full repository support (browse, clone, push)
  • CI/CD pipeline status
  • Snippets

Bitbucket

  • Clone and push
  • Repository browsing

Pull/merge requests from inside the app are GitHub-only today. For GitLab and Bitbucket you get repository, pipeline and snippet access; open MRs/PRs in their web UI.

Git stash

Save changes temporarily without committing:

# Save changes
git stash save "work in progress"

# List stashes
git stash list

# Recover last stash
git stash pop

# Apply specific stash
git stash apply stash@{2}

Commit message tips

Follow Conventional Commits for clear messages:

feat: add OAuth2 authentication
fix: correct email validation error
docs: update README with setup instructions
style: format code with Prettier
refactor: simplify price calculation logic
test: add tests for payment module
chore: update dependencies

Configuration

Global Git

git config --global user.name "Your Name"
git config --global user.email "[email protected]"
git config --global core.editor "pocket-code"

Authentication

PocketCode authenticates over HTTPS with a Personal Access Token (PAT). Generate a token on GitHub, GitLab, or Bitbucket and paste it in — clone, fetch, pull, and push to private repos all work with that single token (on GitHub the token goes in the username field). Every local operation — commit, branch, merge, stash, diff — needs no authentication at all and runs fully offline.


With integrated Git, PocketCode gives you full control over your code. Make commits, manage branches, and collaborate with your team without leaving the PocketCode editor.

The tool behind this article

Code Editor

Ready to try PocketCode?

Download the app and start coding from your mobile.