# Commands Reference Complete reference for jj commands and their options. ## Table of Contents - [Repository Setup](#repository-setup) - [Status and History](#status-and-history) - [Creating and Editing Commits](#creating-and-editing-commits) - [History Rewriting](#history-rewriting) - [Bookmarks (Branches)](#bookmarks-branches) - [Git Operations](#git-operations) - [Operation Log](#operation-log) - [File Operations](#file-operations) - [Workspaces](#workspaces) - [Configuration](#configuration) ## Repository Setup ### `jj git clone` Clone a Git repository: ```bash jj git clone [destination] jj git clone --colocate # Allow git commands (default) jj git clone --no-colocate # jj-only repo jj git clone --branch # Clone specific branch jj git clone --depth # Shallow clone ``` ### `jj git init` Initialize a new repository: ```bash jj git init # New colocated repo (default) jj git init --no-colocate # New jj-only repo jj git init --git-repo # Use existing git repo as backend ``` ## Status and History ### `jj status` (alias: `st`) Show working copy status: ```bash jj status jj st [paths...] # Status for specific paths ``` ### `jj log` Show commit history: ```bash jj log # Default: mutable commits jj log -r # Specific revisions jj log -r '::' # All commits jj log -n 10 # Limit to 10 commits jj log -p # Show patches jj log -s # Summary (files changed) jj log --stat # Show diffstat jj log --no-graph # Flat list, no graph jj log --reversed # Oldest first jj log -T