Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/runekaagaard/diffpilot

Diffpilot serves a local web interface for viewing git diffs across multiple columns on large monitors. Files can be grouped and sorted based on patterns and priorities, and tagged for better overview. All configuration is done in the diffpilot.yaml file in your git repository.
https://github.com/runekaagaard/diffpilot

Last synced: about 1 month ago
JSON representation

Diffpilot serves a local web interface for viewing git diffs across multiple columns on large monitors. Files can be grouped and sorted based on patterns and priorities, and tagged for better overview. All configuration is done in the diffpilot.yaml file in your git repository.

Awesome Lists containing this project

README

        

DIFFPILOT(1) User Commands DIFFPILOT(1)

NAME
diffpilot - intelligent Git diff visualization with file grouping

SYNOPSIS
diffpilot [OPTIONS] path/to/git/project

DESCRIPTION
Diffpilot serves a local web interface for viewing git diffs across multiple
columns on large monitors. Files can be grouped and sorted based on patterns
and priorities, and tagged for better overview. All configuration is done in
the diffpilot.yaml file in your git repository.

OPTIONS
-p, --port=NUMBER
Specify the port number for the web server (default: 3333)

-n, --interval=SECONDS
Refresh interval in seconds, can be fractional (default: 2.0)

--diff-command=COMMAND
Custom diff command (default: "git diff --color=never")
Example: --diff-command="git diff master...HEAD"
Example: --diff-command="git diff --cached"

--diff-local
Shows comprehensive local changes, including:
- Untracked files not yet added to git
- Modified tracked files in the working directory
- Staged changes ready to be committed
- Uncommitted changes in tracked files
Runs two separate git commands:
1. Show diffs for untracked files
2. Show diffs for tracked changes in working directory and staging area

--diff-branch=BRANCH
Shows comprehensive changes in current branch compared to specified branch:
- Untracked files not yet added to git
- Modified tracked files in the working directory
- Staged changes ready to be committed
- Uncommitted changes in tracked files
- All differences since the branch diverged from the specified branch
Runs two separate git commands:
1. Show diffs for untracked files
2. Show diffs compared to the branch's divergence point

--window-title=TITLE
Set custom window title (default: Diffpilot)

-h, --help
Display help information and exit

--no-open
Don't automatically open browser window on startup

CONFIGURATION
The configuration file (diffpilot.yaml) uses YAML format with two main
sections: file_groups and tags.

FILE GROUP MATCHING
When multiple file groups match a file, the FIRST matching group in the
configuration file will be used for priority, and tags.
Order your file groups from most specific to most general.

file_groups:
List of group definitions containing:
- title: Group display name
- glob: File matching pattern
- priority: Sort order (higher numbers first)
- tags: Array of tag names

tags:
Tag definitions containing:
- css_class: CSS class name for styling

EXAMPLE CONFIGURATION
file_groups:
- title: "Python Modules"
glob: "*.py"
priority: 1
tags: [Backend]
- title: "Frontend"
glob:
- "*.html"
- "*.css"
- "*.js"
priority: 2
tags: [Frontend]
- title: "Documentation"
glob:
- "*.md"
- "*.man"
priority: 3
tags: [Documentation]
- title: "Other"
glob: "**"
priority: 4
tags: [Other]

tags:
Backend:
css_class: "bg-success"
Frontend:
css_class: "bg-dark"
Documentation:
css_class: "bg-info"
Other:
css_class: "bg-light"

GLOB PATTERNS
Supports standard glob patterns:
* Matches any characters except /
** Matches any characters including /
? Matches single character
[abc] Matches one character in brackets

EXAMPLES
Start server for current git project:
$ diffpilot .

Show local changes:
$ diffpilot . --diff-local

Compare with main branch:
$ diffpilot . --diff-branch main

Start with 5 second refresh:
$ diffpilot -n 5 .

Start on specific port:
$ diffpilot -p 8080 /path/to/project

Show staged changes:
$ diffpilot . --diff-command="git diff --cached"

Set custom window title:
$ diffpilot . --window-title "My Project Diffs"

FILES
./diffpilot.yaml
Configuration file in repository root

EXIT STATUS
0 Success
1 Various errors
2 Configuration error

BUGS
Report bugs to: https://github.com/runekaagaard/diffpilot/issues

SEE ALSO
git-diff(1), git(1)

Diffpilot 1.0 November 2024 DIFFPILOT(1)