NI Package Management Idea Exchange

cancel
Showing results for 
Search instead for 
Did you mean: 

Add ability to exclude files with filter in NI Package Builder

Status: New

When you add  folder in NI Package Builder it add all the files included. It can be usefull to remove automatically somes files or folder with filters.

 

Just to give some examples. I have to include some Python Script. Python is generating *.pyc files in _pycache_ folder. If I have the ability to exclude automatically a list of extension file, or file/folder of list based on regular expressio, it can be very usefull. 

 

My source code is under SVN source code control. When you selet a folder, it populates also hidden folder. So it adds my ".svn" folder.

 

Add ability to exclude hidden folder and have the first filter will help me better manage my files to distribute. This can be added to the propoerty page of the input folder.

 

Best regards

Maxime R.  

  CLA - Certified LabVIEW Architect / Architecte LabVIEW Certifié
  CTA - Certified TestStand Architect / Architecte TestStand Certifié

3 Comments
Member

Hi Maxine,

 

This type of functionality does exist in part in NI Package Builder by modifying the'DiscoveryExclusion.txt' in the '[LocalAppData]\National Instruments\NI Package Builder\' directory. 

 

This file is not well documented yet, but it is used to exclude or include discovery for certain files or directories. For example I modified the Exclude Paths and Include Paths sections, I removed the [User Desktop] path from the Include Paths so I can add the '[User Desktop]\\Project\\.*.bmp' line to my Exclude Paths. This will exclude from discovery any .bmp files in the Project Directory or its subdirectories. So when I add my Project file I get all my other files but it does not discover my .bmp files. See the partial snipped below:

"

[Exclude Paths]
[Windows]\\WinSxS
[User Desktop]\\Project\\.*.bmp

[Include Paths]
[Documents]\\National Instruments
[My Documents]

"

Dane S.
Product Support Engineer
National Instruments
Active Participant

Hi,

 

Thanks for the trick. I try to find it by myself without success. I already change it to include some windows dll that I need to deploy.

In my point of view, this configuration should be inside the solution itself.

 

To filter, you need to change a file in LocalAppData which is hidden by default. Hidden file or folder are more me files or folder that user don't have to change.

It applies for all projects of the computer. You can imagine to have different projets to build on the same computer with different specs. If may brake your build if you forgot to change it.

If you have to build the pacakge on differents computer, you may have differents results due to this configuration file if you forgot to update it.

 

in any case, I appreciate your quick support that workaround my problem.

 

Best regards

 

MaximeR

Maxime R.  

  CLA - Certified LabVIEW Architect / Architecte LabVIEW Certifié
  CTA - Certified TestStand Architect / Architecte TestStand Certifié

Active Participant

Maxime, the original purpose of the file was to apply to all solutions to prevent users from include Microsoft and some NI files in their packages. FWIW, we would like to expose this type of feature more formally in the application in the future. Thanks for the feedback that you would be interested in per solution settings for this type of functionality.

Scott Richardson
National Instruments