Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
41 changes: 41 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,46 @@
# Изменения

## 1.7.1 — 2026-10-25

Мелкий текст стал чётче, статус больших рабочих папок считается вдвое быстрее, а
открытие репозитория больше не задерживает интерфейс. Цифры измерены на Windows,
20 потоков.

### Чёткий текст

- Мелкий текст рисуется с вертикальным хинтингом и подъёмом контраста тонких
штрихов: высоты строчных и заглавных букв попадают на целые пиксели, тёмный
текст на светлом фоне стал плотнее. Ширины строк и раскладка не меняются.
Субпиксельное сглаживание не включается: в удалённом сеансе от него нет толку.
Для этого движок headless-gui обновлён до v3.43.0.

### Скорость на больших рабочих папках

- Статус папки на 50 тысяч файлов вместе с неизменёнными файлами (так его
запрашивает панель «Файлы») — 53 мс вместо 103 и 41 МБ вместо 122. Атрибуты
файлов берутся из кэша без построения правил заново, а для каждого файла
проверяется только то, нужен ли ему внешний фильтр.
- Каталог, где лежат отслеживаемые файлы, читается за скан один раз: поиск
неотслеживаемых файлов берёт уже прочитанный листинг. Статус 50 тысяч файлов —
30 мс вместо 44.
- Открытие репозитория на 80 тысяч файлов задерживает интерфейс на 19 мс вместо
250–440: первый снимок слежения за папкой делается в фоне, и проверка статуса
дожидается его, чтобы не пропустить изменения сразу после открытия. Новый список
игнорируемых каталогов передаётся работающему слежению, а не перезапускает его с
полным обходом папки.

### Исправления

- Подгрузка следующей страницы журнала больше не сбрасывает выделенный коммит и не
перестраивает всю таблицу.
- В Blame коммит открывается одним щелчком по его ссылке, над ней курсор-рука.
- Защищённое соединение по медленной сети ждёт минуту вместо 15 секунд, а таймер
ответа сервера запускается только после отправки запроса. Если соединение так и не
установилось, Go.Git пишет об этом прямо, а не «context deadline exceeded».
- На Windows коммит, сделанный сразу после того, как git или антивирус отпустили
`packed-refs.lock`, больше не падает с «Access is denied»: пока система
дозакрывает старый файл, Go.Git ждёт до секунды, как и при занятом замке.

## 1.7.0 — 2026-10-16

Релиз про скорость: статус, журнал, счётчики веток и чтение объектов на больших
Expand Down
5 changes: 2 additions & 3 deletions README.en.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ interface. An alternative to the paid SmartGit.
window; the layout is remembered.
- Localization: Russian and English out of the box, any other language is a single JSON file.

## What 1.7.0 can already do
## What 1.7.1 can already do

**Interface.** The menu and toolbar mirror SmartGit; the toolbar is configured
in a separate window and stored in `config.toml`. Dock panels:
Expand Down Expand Up @@ -83,8 +83,7 @@ what to look at when something goes wrong: [USER_GUIDE.md](USER_GUIDE.md)

## What is still missing

Horizontal scrolling in the compare and conflict-resolution windows (waiting
on the engine), the GitHub and Jira integrations, `core.sharedRepository`.
The GitHub and Jira integrations, `core.sharedRepository`.
The order of work is in docs/RELEASE_PLAN.md.

## Building
Expand Down
5 changes: 2 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
раскладка запоминается.
- Локализация: русский и английский из коробки, любой другой язык — один JSON-файл.

## Что уже умеет 1.7.0
## Что уже умеет 1.7.1

**Интерфейс.** Меню и панель инструментов повторяют SmartGit; панель
настраивается в отдельном окне и хранится в `config.toml`. Док-панели:
Expand Down Expand Up @@ -82,8 +82,7 @@ Windows, Secret Service на Linux, мастер-пароль или файл к

## Чего ещё нет

Горизонтальная прокрутка в окнах сравнения и разрешения конфликтов (ждём
движок), интеграция с GitHub и Jira, `core.sharedRepository`.
Интеграция с GitHub и Jira, `core.sharedRepository`.
Порядок работ — в docs/RELEASE_PLAN.md.

## Сборка
Expand Down
94 changes: 40 additions & 54 deletions RELEASE_NOTES.md
Original file line number Diff line number Diff line change
@@ -1,58 +1,44 @@
# Go.Git 1.7.0 — Speed
# Go.Git 1.7.1 — Sharper text, faster big working trees

Status, the journal, branch counters and object reading are noticeably faster on
big repositories, and Go.Git now writes the commit graph itself.
Small text is sharper, the status of a big working tree takes half the time, and
opening a repository no longer holds up the interface.

All numbers below were measured on Windows with a 20-thread processor.

## Working tree status

- Status of a repository with 50 thousand files takes 0.12 s instead of 5.1 s.
Almost all the time went into stating each file through a path that is opened
component by component. A directory is now read once and its files are described
from that listing; only small directories and files missing from a listing are
stated one by one.
- The index is compared with HEAD through the cache tree: if a directory has the
same tree as in HEAD, it is not read at all. With nothing staged, no tree below
the root is read.
- Untracked directories are walked in parallel, each read once. With 20 thousand
untracked files the status takes 23 ms instead of 46 ms, with 20 thousand ignored
files 24 ms instead of 76 ms. The ignore and attribute matchers no longer wait for
each other behind a lock.

## Journal and history

- If a repository has no commit graph, Go.Git writes it in the background after the
repository is opened. With a graph the journal streams its first page instead of
walking the whole history. The settings `core.commitGraph` and
`gc.writeCommitGraph` are honoured, and shallow clones are left alone.
- Parsing a commit makes almost four times fewer allocations: a walk over 10 thousand commits goes
from 330 thousand allocations to 90 thousand and from 12.1 ms to 7.5 ms.
- The journal hands its rows to the grid once per page instead of copying them
twice: with 100 thousand rows 65 ms instead of 127 ms and 284 MB instead of 635 MB.
- A refresh no longer restarts the journal when no branch, tag or remote moved.

## Branch counters

- The ahead and behind counters are computed once for each pair of branch tips and
remembered, so a refresh recounts only the branches that moved. All walks of one
computation share the commits they have parsed, and the counting reuses the open
repository and its cached commit graph.

## Objects and references

- Pack indexes keep their name table in memory and, together with packfiles, are
read through a memory mapping on Windows and Linux (with a fallback to plain
reads). Looking an object up in a pack index takes about 70 ns.
- `packed-refs` is parsed once while the file does not change instead of on every
miss.
- A missing object no longer rescans the pack directory when it has not changed.
- The pack that answered last is searched first; the decompression buffers are
pooled; the parsed object cache sweeps dead entries lazily; the raw object cache
is split into shards so parallel readers stop sharing one lock.

## Diagnostics

- `GOGIT_TRACE_STARTUP=1` writes the startup steps with their time since the process
start into `gogit.log`: logger opened, application built, repository opened,
window started, first journal page and working tree status shown.
## Sharper text

- Small text is drawn with vertical hinting and a contrast boost for thin strokes:
the heights of lowercase and capital letters land on whole pixels, and dark text
on a light background looks denser. Line widths and layout do not change.
Subpixel smoothing stays off because it is useless in a remote session. The
headless-gui engine is updated to v3.43.0 for this.

## Big working trees

- Status of a working tree with 50 thousand files, unchanged files included (the
way the Files pane asks for it), takes 53 ms instead of 103 ms and 41 MB instead
of 122 MB. File attributes come from the cache without rebuilding the rule stack,
and for every file only the question of whether it needs an external filter is
asked.
- A directory with tracked files is read once per scan: the search for untracked
files reuses the listing that was already read. Status of 50 thousand files takes
30 ms instead of 44 ms.
- Opening a repository with 80 thousand files holds up the interface for 19 ms
instead of 250–440 ms. The working tree watcher takes its first snapshot in the
background, and the status scan waits for it so that no change made right after
opening is lost. A new set of ignored directories reaches the running watcher
instead of restarting it with a full walk of the tree.

## Fixes

- Loading the next page of the journal no longer drops the selected commit or
rebuilds the whole table.
- In Blame a commit opens with a single click on its link, and the cursor turns
into a hand over it.
- A secure connection over a slow network waits a minute instead of 15 seconds, and
the server response timer starts only after the request is sent. When the
connection never comes up, Go.Git says so instead of "context deadline exceeded".
- On Windows a commit made right after git or a virus scanner let go of
`packed-refs.lock` no longer fails with "Access is denied": while the system is
still closing the old file, Go.Git waits up to a second, as it does for a busy
lock.
3 changes: 2 additions & 1 deletion USER_GUIDE.md
Original file line number Diff line number Diff line change
Expand Up @@ -259,7 +259,8 @@ git-клиентом (или из консоли), Go.Git тоже обнару
**Кто менял строки** (Blame) — из контекстного меню файла или кнопки
«Кто менял» на панели инструментов: список строк файла с автором, коммитом,
временем и текстом; выбор строки показывает, из какого коммита она пришла, и
может передать выделение в Investigate. **Исследовать** (Investigate,
может передать выделение в Investigate; щелчок по ссылке коммита открывает
этот коммит. **Исследовать** (Investigate,
`git log -L`) — история изменений именно выбранных строк, доступна из списка
файлов, из панели «Изменения» и из Blame; список найденных коммитов можно
остановить кнопкой «Остановить», не дожидаясь конца истории.
Expand Down
6 changes: 3 additions & 3 deletions cmd/gogit/winres/winres.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
"0409": {
"identity": {
"name": "Go.Git",
"version": "1.7.0.0"
"version": "1.7.1.0"
},
"description": "Go.Git git client",
"minimum-os": "win7",
Expand All @@ -35,8 +35,8 @@
"#1": {
"0000": {
"fixed": {
"file_version": "1.7.0.0",
"product_version": "1.7.0.0"
"file_version": "1.7.1.0",
"product_version": "1.7.1.0"
},
"info": {
"0409": {
Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ require (
github.com/BurntSushi/toml v1.6.0
github.com/godbus/dbus/v5 v5.2.2
github.com/jcmturner/gokrb5/v8 v8.4.4
github.com/oops1/headless-gui/v3 v3.35.1
github.com/oops1/headless-gui/v3 v3.43.0
golang.org/x/crypto v0.56.0
golang.org/x/sys v0.47.0
golang.org/x/text v0.41.0
Expand Down
14 changes: 6 additions & 8 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -30,14 +30,12 @@ github.com/jcmturner/gokrb5/v8 v8.4.4 h1:x1Sv4HaTpepFkXbt2IkL29DXRf8sOfZXo8eRKh6
github.com/jcmturner/gokrb5/v8 v8.4.4/go.mod h1:1btQEpgT6k+unzCwX1KdWMEwPPkkgBtP+F6aCACiMrs=
github.com/jcmturner/rpc/v2 v2.0.3 h1:7FXXj8Ti1IaVFpSAziCZWNzbNuZmnvw/i6CqLNdWfZY=
github.com/jcmturner/rpc/v2 v2.0.3/go.mod h1:VUJYCIDm3PVOEHw8sgt091/20OJjskO/YJki3ELg/Hc=
github.com/oops1/headless-gui/v3 v3.23.0 h1:4GEXBzab3jIsvXf8xJsWdDzIc3L5wkFW89uQxkjbLls=
github.com/oops1/headless-gui/v3 v3.23.0/go.mod h1:KfrQeckxm94JygZq21eM6fpaQCYhUkL1vrb71WY5to8=
github.com/oops1/headless-gui/v3 v3.25.0 h1:eWyw/UHozczW62RJbr3UGVAFmKGpgMypwyw4cLbQ2X8=
github.com/oops1/headless-gui/v3 v3.25.0/go.mod h1:KfrQeckxm94JygZq21eM6fpaQCYhUkL1vrb71WY5to8=
github.com/oops1/headless-gui/v3 v3.26.0 h1:G4/I3vOhmImyzctsnvG2qTrDwEbMCwiCtcndPosSNnQ=
github.com/oops1/headless-gui/v3 v3.26.0/go.mod h1:KfrQeckxm94JygZq21eM6fpaQCYhUkL1vrb71WY5to8=
github.com/oops1/headless-gui/v3 v3.35.1 h1:3NmKdX2yUIatqdP+GFfNDXbBWi7F201gfivHzoq5SKc=
github.com/oops1/headless-gui/v3 v3.35.1/go.mod h1:KfrQeckxm94JygZq21eM6fpaQCYhUkL1vrb71WY5to8=
github.com/oops1/headless-gui/v3 v3.39.0 h1:a7wJdqsR+yhjSJrSVgD9bWVchDa+oeu7LiP45eQUwrc=
github.com/oops1/headless-gui/v3 v3.39.0/go.mod h1:KfrQeckxm94JygZq21eM6fpaQCYhUkL1vrb71WY5to8=
github.com/oops1/headless-gui/v3 v3.42.0 h1:meVrKaf7DSzJA/HuyjN3KdKs6XenzOXARWqi5QWPPv8=
github.com/oops1/headless-gui/v3 v3.42.0/go.mod h1:KfrQeckxm94JygZq21eM6fpaQCYhUkL1vrb71WY5to8=
github.com/oops1/headless-gui/v3 v3.43.0 h1:qY/PhHjndWu4CMXCAcgqSrqVlQ0z7hV8FeC34jVhhXo=
github.com/oops1/headless-gui/v3 v3.43.0/go.mod h1:KfrQeckxm94JygZq21eM6fpaQCYhUkL1vrb71WY5to8=
github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM=
github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
Expand Down
1 change: 1 addition & 0 deletions internal/app/app.go
Original file line number Diff line number Diff line change
Expand Up @@ -417,6 +417,7 @@ func NewFromXAML(cfg *config.Config, paths config.Paths, xaml []byte, log *slog.
root.Title = i18n.T("App.Title")

a.eng = engine.New(cfg.Window.Width, cfg.Window.Height, targetFPS)
a.eng.SetTextQuality(engine.TextQuality{Hinting: true, Contrast: engine.DefaultTextContrast})
a.eng.SetRoot(root)
a.eng.SetOnModalClosed(func(widget.ModalWidget) { a.releaseClosedDialogs() })
a.startPostQueue()
Expand Down
9 changes: 9 additions & 0 deletions internal/app/app_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ import (
"strings"
"testing"

"github.com/oops1/headless-gui/v3/engine"
"github.com/oops1/headless-gui/v3/widget"

"github.com/oops1/gogit/internal/config"
Expand Down Expand Up @@ -58,6 +59,14 @@ func TestNewLoadsMainWindow(t *testing.T) {
}
}

func TestNewTurnsOnHintedHighContrastText(t *testing.T) {
a := newTestApp(t)
got := a.Engine().TextQuality()
if !got.Hinting || got.Contrast != engine.DefaultTextContrast || got.LCD {
t.Fatalf("text quality = %+v, want hinting with default contrast and no LCD", got)
}
}

func TestMenuStructure(t *testing.T) {
a := newTestApp(t)
items := a.menu.Items()
Expand Down
1 change: 1 addition & 0 deletions internal/app/transporterrors.go
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ var transportErrorKeys = []struct {
{transport.ErrProtocolNotAllowed, "Operation.Error.ProtocolNotAllowed"},
{transport.ErrProxyAuthRequired, "Operation.Error.ProxyAuthRequired"},
{transport.ErrTLSConfig, "Operation.Error.TLSConfig"},
{transport.ErrTLSHandshakeTimeout, "Operation.Error.TLSHandshakeTimeout"},
}

func localizeOperationError(err error) error {
Expand Down
26 changes: 22 additions & 4 deletions internal/app/watch.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@ type watcherIface interface {
Poke()
Pause()
Resume()
Ready() <-chan struct{}
SetSkipDirs(dirs []string)
}

func newRealWatcher(layout gitrepo.Layout, opts watch.Options) watcherIface {
Expand Down Expand Up @@ -50,14 +52,30 @@ func (a *App) ignoredDirectories() []string {
}

func (a *App) syncWatcherSkips() {
skip := a.ignoredDirectories()
a.watchMu.Lock()
current := a.watchSkip
running := a.watcher != nil
w := a.watcher
changed := w != nil && !slices.Equal(a.watchSkip, skip)
if changed {
a.watchSkip = skip
}
a.watchMu.Unlock()
if !running || slices.Equal(current, a.ignoredDirectories()) {
if changed {
w.SetSkipDirs(skip)
}
}

func (a *App) waitForWatcherBaseline(ctx context.Context) {
a.watchMu.Lock()
w := a.watcher
a.watchMu.Unlock()
if w == nil {
return
}
a.restartWatcherForCurrentRepository()
select {
case <-ctx.Done():
case <-w.Ready():
}
}

func (a *App) runWatcher(ctx context.Context, w watcherIface) {
Expand Down
Loading
Loading