# git: Move git-blame outside of git job queue \(\#43565\) · gitcafe/zed

[View on GitCafe](https://git.cafe/gitcafe/zed/commit/05b999bb7cbfcf148fa650b9d7f6ab88a4d46e39)

Repository: [gitcafe/zed](https://git.cafe/gitcafe/zed)

Visibility: public

Requested revision: 05b999bb7cbfcf148fa650b9d7f6ab88a4d46e39

Requested commit: 05b999bb7cbfcf148fa650b9d7f6ab88a4d46e39

Commit: 05b999bb7cbfcf148fa650b9d7f6ab88a4d46e39

Tree: 974f1de460669a2fd04057a649d2b4b553b7650f

Author: Jakub Konka

Committer: GitHub

## Message

```
git: Move git-blame outside of git job queue (#43565)

We restructured `struct Repository` a bit so that it now stores a shared
task of `enum RepositoryState`. This way, we can now re-use it outside
of the git job queue when spawning a git job a standalone bg task. An
example here would be `git-blame` that does not require any file locks
and is not susceptible to git job ordering.

As a result of this change, loading (and modifying) a file that contains
a huge git history will no longer block other git operations on the repo
such as staging/unstaging/committing.

Release Notes:

- Improved overall git experience when loading buffers with massive git
history where they would block other git jobs from running (such as
staging/unstaging/commiting). Now, git-blame will run separately from
the git job queue on the side and the buffer with blame hints when
finished thus unblocking other git operations.

Co-authored-by: Cole Miller <cole@zed.dev>
```

## Parents

- [d099ea048e9d460072917308540f2028e892c39c](https://git.cafe/gitcafe/zed/commit/d099ea048e9d460072917308540f2028e892c39c?format=markdown)

[Source at this commit](https://git.cafe/gitcafe/zed/tree/05b999bb7cbfcf148fa650b9d7f6ab88a4d46e39?format=markdown)
