emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH] Make update_autogen work in git worktrees


From: Robert Pluim
Subject: Re: [PATCH] Make update_autogen work in git worktrees
Date: Thu, 22 Mar 2018 11:53:42 +0100

Andreas Schwab <address@hidden> writes:

> On Mär 22 2018, Robert Pluim <address@hidden> wrote:
>
>> diff --git a/admin/update_autogen b/admin/update_autogen
>> index d211867479..f4c2c39825 100755
>> --- a/admin/update_autogen
>> +++ b/admin/update_autogen
>> @@ -47,7 +47,7 @@ PD=
>>  cd ../
>>  [ -d admin ] || die "Could not locate admin directory"
>>  
>> -[ -d .git ] || die "No .git directory"
>> +[ -d .git ] || git rev-parse --git-dir > /dev/null 2>&1 || die "Not in a 
>> git repository"
>
> Alternatively, you could test for .git being a plain file.

Yes, but I think git itself is better at working out whether weʼre in
a repository than just a script testing files.

Robert



reply via email to

[Prev in Thread] Current Thread [Next in Thread]