@@ -19,7 +19,7 @@ public class CodeQLInstallation
1919 public string CLIBundle { get ; set ; }
2020 public string StandardLibraryIdent { get ; set ; }
2121 public bool EnableCustomCodeQLBundles { get ; set ; }
22- public string [ ] ExportedCustomizationPacks { get ; set ; }
22+ public QLTCustomizationPack [ ] CustomizationPacks { get ; set ; }
2323 public bool QuickBundle { get ; set ; }
2424 public string Base { get ; set ; }
2525
@@ -44,7 +44,7 @@ public static CodeQLInstallation LoadFromConfig(QLTConfig c)
4444 CLIBundle = config . CodeQLCLIBundle ,
4545 StandardLibraryIdent = config . CodeQLStandardLibraryIdent ,
4646 StandardLibraryVersion = config . CodeQLStandardLibrary ,
47- ExportedCustomizationPacks = config . ExportedCustomizationPacks ,
47+ CustomizationPacks = config . CustomizationPacks ,
4848 Base = config . Base
4949 } ;
5050
@@ -53,9 +53,9 @@ public static CodeQLInstallation LoadFromConfig(QLTConfig c)
5353
5454 public void LogPacksToBeBuilt ( )
5555 {
56- if ( ExportedCustomizationPacks != null )
56+ if ( CustomizationPacks != null )
5757 {
58- foreach ( var p in ExportedCustomizationPacks )
58+ foreach ( var p in CustomizationPacks )
5959 {
6060 Log < CodeQLInstallation > . G ( ) . LogInformation ( $ "Pack: { p } ") ;
6161 }
@@ -274,14 +274,16 @@ private void CustomBundleInstall()
274274
275275 var workingDirectory = Path . GetFullPath ( Base ) ;
276276
277- if ( ExportedCustomizationPacks == null || ExportedCustomizationPacks . Length == 0 )
277+ if ( CustomizationPacks == null || CustomizationPacks . Length == 0 )
278278 {
279279 throw new Exception ( "No packs are set to be exported. Please add at least one pack to export in your `qlt.conf.json` file under the property `ExportedCustomizationPacks`." ) ;
280280 }
281281
282282 Log < CodeQLInstallation > . G ( ) . LogInformation ( $ "Building custom bundle. This may take a while...") ;
283283
284- var packs = string . Join ( " " , ExportedCustomizationPacks ) ;
284+ var packsToExport = CustomizationPacks . Where ( p => p . Export == true ) . Select ( p => p . Name ) . ToArray ( ) ;
285+
286+ var packs = string . Join ( " " , packsToExport ) ;
285287 // next, we run the bundling tool.
286288 // typical command line:
287289 // codeql_bundle -b .\scratch\codeql-bundle-win64.tar.gz -o scratch\out -w .\tests\workspace\ --help
0 commit comments