[Qt-creator] fatal: Not a git repository when creating a new project

Harri Pasanen harri at mpaja.com
Fri Dec 14 12:27:23 CET 2012


Hmm...

I just updated my qt-creator and running from the build tree,

Built on Dec 14 2012 at 11:32:16


Still failing here:

Failed to add '/home/harri/tmp/untitled/main.cpp' to the version control 
system.

12:13 Executing in /home/harri/tmp/untitled: /usr/bin/git add 
--intent-to-add main.cpp

Cannot add 1 file(s) to "/home/harri/tmp/untitled": fatal: Not a git 
repository (or any of the parent directories): .git


I see these in konsole where I started qtcreator:


harri at touho:~/src/qt-creator$ SOFT ASSERT: "QDir(dir).isAbsolute()" in 
file vcsmanager.cpp, line 85
QFileInfo::absolutePath: Constructed with empty filename
SOFT ASSERT: "!dirS.isEmpty() && !checkFile.isEmpty()" in file 
vcsbaseplugin.cpp, line 740
SOFT ASSERT: "QDir(dir).isAbsolute()" in file vcsmanager.cpp, line 125


It seems to fail if the project directory does not exist yet, in my case 
"/home/harri/tmp/untitled"

If I create the directory manually, it warns about project existing, but 
the git init then is correctly done.


-Harri





On 12/14/2012 10:37 AM, Ziller Eike wrote:
>> ________________________________________
>> From: qt-creator-bounces+eike.ziller=digia.com at qt-project.org [qt-creator-bounces+eike.ziller=digia.com at qt-project.org] on behalf of Harri Pasanen [harri at mpaja.com]
>> Sent: 14 December 2012 09:14
>> To: qt-creator at qt-project.org
>> Subject: [Qt-creator] fatal: Not a git repository when creating a new project
>>   
>> A fairly minor issue I ran into, but could be confusing for newbies:
>>   
>>   
>> Creating a new Qt Console project from scratch, the wizard default to
>> "Add to version control (git)" for me.
>> I figured that it will create the .git repository for me, but no, I got:
> It should create a repository for you, and when I try here I get:
>
> 10:27 Executing in /private/tmp/untitled: /usr/bin/git init
> Initialized empty Git repository in /private/tmp/untitled/.git/
>
> 10:27 Executing in /private/tmp/untitled: /usr/bin/git add --intent-to-add main.cpp
> [....]
>
> Br, Eike
>
>>   
>> 08:58 Executing in /home/harri/test/untar: /usr/bin/git add
>> --intent-to-add main.cpp
>>   
>> Cannot add 1 file(s) to "/home/harri/test/untar": fatal: Not a git
>> repository (or any of the parent directories): .git
>>   
>>   
>> It did create the main.cpp and untar.pro before bailing out, the new
>> project was not opened.
>>   
>>   
>>   
>> This is with Kubuntu 12.04 amd64
>>   
>> Qt Creator 2.6.81
>>   
>> Based on Qt 4.8.1 (64 bit)
>>   
>> Built on Dec 5 2012 at 18:09:25
>>   
>>   
>> -Harri
> --
> Eike Ziller
> Senior Software Developer
>
> Digia Germany GmbH
> Rudower Chaussee 13, 12489 D-Berlin
> Sitz der Gesellschaft: Berlin, Registergericht: Amtsgericht Charlottenburg, HRB 144331 B,
> Geschäftsführer: Mika Pälsi, Juha Varelius, Anja Wasenius




More information about the Qt-creator mailing list