Bug 1439994

Summary: /build-aux/*.pl is gitignored
Product: [Community] Virtualization Tools Reporter: steve13814
Component: libvirtAssignee: Libvirt Maintainers <libvirt-maint>
Status: CLOSED NEXTRELEASE QA Contact:
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: unspecifiedCC: jdenemar, libvirt-maint, rbalakri
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2017-04-07 08:10:25 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description steve13814 2017-04-07 03:37:58 UTC
Description of problem:
In libvirt .gitignore has the following rule:

/build-aux/
!/build-aux/*.pl

According to the git document:

An optional prefix "!" which negates the pattern; any matching file excluded by a previous pattern will become included again. It is not possible to re-include a file if a parent directory of that file is excluded. Git doesn’t list excluded directories for performance reasons, so any patterns on contained files have no effect, no matter where they are defined.

The rule should be modified as followed,

/build-aux/*
!/build-aux/*.pl


Version-Release number of selected component (if applicable):


How reproducible:
always

Steps to Reproduce:
1.git clone https://github.com/libvirt/libvirt.git
2.touch build-aux/test.pl


Actual results:
git status shows nothing is modified

Expected results:
git status shows new file

Additional info:

Comment 1 Jiri Denemark 2017-04-07 08:10:25 UTC
Fixed by:

commit f0ad8e7ee083c4bf196af42c615aac803be08460
Refs: v3.2.0-57-gf0ad8e7ee
Author:     Jiri Denemark <jdenemar>
AuthorDate: Fri Apr 7 08:50:21 2017 +0200
Commit:     Jiri Denemark <jdenemar>
CommitDate: Fri Apr 7 10:08:33 2017 +0200

    Properly ignore files in build-aux directory

    We want to ignore all files except *.pl in build-aux directory, however
    the unignore pattern "!/build-aux/*.pl" doesn't have any effect because
    a previous "/build-aux/" pattern ignores the directory itself rather
    than individual files in it.

    https://bugzilla.redhat.com/show_bug.cgi?id=1439994

    Signed-off-by: Jiri Denemark <jdenemar>