[llvm] r240973 - Simplify .gitignore: projects/* => projects/*/

Chris Bieneman beanz at apple.com
Tue Jul 7 09:17:15 PDT 2015


I see the other thread now.

What if instead we did something like this:

diff --git a/.gitignore b/.gitignore
index f3424d2..e3d191d 100644
--- a/.gitignore
+++ b/.gitignore
@@ -43,7 +43,9 @@ autoconf/autom4te.cache
 # Directories to ignore (do not add trailing '/'s, they skip symlinks).
 #==============================================================================#
 # External projects that are tracked independently.
-projects/*/
+projects/*
+!projects/*.*
+!projects/Makefile
 # Clang, which is tracked independently.
 tools/clang
 # LLDB, which is tracked independently.

It still wouldn’t be perfect, but it is less error-prone since most files other than Makefiles have extensions.

Thoughts?
-Chris

> On Jul 7, 2015, at 10:55 AM, Duncan P. N. Exon Smith <dexonsmith at apple.com> wrote:
> 
> 
>> On 2015-Jul-07, at 07:44, Chris Bieneman <beanz at apple.com> wrote:
>> 
>> Was there a driving reason for this change or was this just to simplify things?
> 
> It was in response to r240771.  It's error prone to require explicit
> inclusions for each file under version control.
> 
>> The reason I’m asking is because this is not functionally equivalent to what existed before. With this change, if you symlink projects under the projects folder the symlinks don’t get ignored by git.
> 
> I knew it wasn't functionally equivalent -- that was actually the
> point -- but I hadn't considered symlink-ing in projects since that's
> not part of my flow.  Feel free to revert!
> 
>>> On Jun 29, 2015, at 12:43 PM, Duncan P. N. Exon Smith <dexonsmith at apple.com> wrote:
>>> 
>>> Author: dexonsmith
>>> Date: Mon Jun 29 12:43:26 2015
>>> New Revision: 240973
>>> 
>>> URL: http://llvm.org/viewvc/llvm-project?rev=240973&view=rev
>>> Log:
>>> Simplify .gitignore: projects/* => projects/*/
>>> 
>>> Avoid listing inclusions (like `!projects/LLVMBuild.txt`) for files
>>> directly underneath `projects/` in `.gitignore`.  Instead, change the
>>> `projects/*` exclusion to the more specific `projects/*/`.
>>> 
>>> Modified:
>>>  llvm/trunk/.gitignore
>>> 
>>> Modified: llvm/trunk/.gitignore
>>> URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/.gitignore?rev=240973&r1=240972&r2=240973&view=diff
>>> ==============================================================================
>>> --- llvm/trunk/.gitignore (original)
>>> +++ llvm/trunk/.gitignore Mon Jun 29 12:43:26 2015
>>> @@ -43,10 +43,7 @@ autoconf/autom4te.cache
>>> # Directories to ignore (do not add trailing '/'s, they skip symlinks).
>>> #==============================================================================#
>>> # External projects that are tracked independently.
>>> -projects/*
>>> -!projects/CMakeLists.txt
>>> -!projects/LLVMBuild.txt
>>> -!projects/Makefile
>>> +projects/*/
>>> # Clang, which is tracked independently.
>>> tools/clang
>>> # LLDB, which is tracked independently.
>>> 
>>> 
>>> _______________________________________________
>>> llvm-commits mailing list
>>> llvm-commits at cs.uiuc.edu
>>> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
>> 
> 





More information about the llvm-commits mailing list