Error codes · Git

PULSE-GIT-011 Folder - bare repository without project files

What does this mean

The folder you selected as a project is a bare repository: it contains only the git history, but no project files. Such a repository is created so that changes can be sent to it, and they work in its copy. Pulse did not add it to the project, your files and history are intact.

Why does this happen

A bare repository is created with the command git init --bare or git clone --bare, and its folder is usually named with .git at the end - for example, ~/origin.git. There are no working files inside: only HEAD, objects, refs and config. Pulse tasks, agent branches, the editor, and the Git screen all work on project files, so there's nothing for them to work with in a bare repository. If such a repository has already been added before, git responds to every action fatal: this operation must be run in a work tree - it's the same reason.

What to do

  1. Click "Clone a working copy from it." A cloning window will open with the path to this repository: choose where to put the copy and click “Clone”. The copy will become the project, and the bare repository will become its remote repository origin: changes will be sent to it.
  2. The same in the terminal: git clone ~/origin.git ~/code/origin - and add the project folder ~/code/origin via “Add project” → “Select folder”.
  3. If a bare repository was added earlier, remove it from the list of projects in Settings → Repositories and add a working copy of it.

When to write to support

Write to us if there are project files in the selected folder (git status it answers without an error), but Pulse still calls it a bare repository. Click “Send report” in the error card - the code and details will already be entered, the secrets are hidden in them.