threads / discuss / 18539

.git/index

Subject: .git/index

## tl;dr

4 messages between Mar 25, 2009 and Mar 25, 2009.

replies: 3people: 3as markdown or json

Jon Smirl· Mar 25, 2009, 17:16 UTC · lore

I pushed a repo up to my server. I want to view this repo with gitweb but it is not visible in my project list like my other projects. I suspect this is because the newly pushed repo is missing .git/index. I ran update-server-info on the repo and that didn't create .git/index. What command builds this index?

-- 
Jon Smirl
jonsmirl@gmail.com
Julian Phillips· Mar 25, 2009, 17:52 UTC · re: Jon Smirl · lore

Re: .git/index

On Wed, 25 Mar 2009, Jon Smirl wrote:
Show 5 quoted lines
> I pushed a repo up to my server. I want to view this repo with gitweb
> but it is not visible in my project list like my other projects. I
> suspect this is because the newly pushed repo is missing .git/index. I
> ran update-server-info on the repo and that didn't create .git/index.
> What command builds this index?

.git/index is the default name used for what is commonly referred to as the staging area these days. It's only needed when you have a work tree, and is expected to be absent from a bare repository.

A more likely cause for a repository to not be picked up by gitweb is file permissions.

-- 
Julian

  ---
<MFGolfBal> rit/ara:  There's something really demented about UNIX
             underwear...
Jon Smirl· Mar 25, 2009, 18:03 UTC · re: Julian Phillips · lore

Re: .git/index

On Wed, Mar 25, 2009 at 1:52 PM, Julian Phillips <julian@quantumfyre.co.uk> wrote:

Show 14 quoted lines
> On Wed, 25 Mar 2009, Jon Smirl wrote:
>
>> I pushed a repo up to my server. I want to view this repo with gitweb
>> but it is not visible in my project list like my other projects. I
>> suspect this is because the newly pushed repo is missing .git/index. I
>> ran update-server-info on the repo and that didn't create .git/index.
>> What command builds this index?
>
> .git/index is the default name used for what is commonly referred to as the
> staging area these days.  It's only needed when you have a work tree, and is
> expected to be absent from a bare repository.
>
> A more likely cause for a repository to not be picked up by gitweb is file
> permissions.
It needed to be added to the gitweb projects file.
Show 8 quoted lines
>
> --
> Julian
>
>  ---
> <MFGolfBal> rit/ara:  There's something really demented about UNIX
>            underwear...
>
-- 
Jon Smirl
jonsmirl@gmail.com
Junio C Hamano· Mar 25, 2009, 18:02 UTC · re: Jon Smirl · lore

Re: .git/index

The index is associated with the work tree. Since gitweb is supposed to read and show the history and never the work tree state, it would be a bug if it required it to operate.

← back to recent threads