private void ExpandFiles(IPackage package) { var batchProcessor = FileSystem as IBatchProcessor <string>; try { var files = package.GetFiles().ToList(); if (batchProcessor != null) { // Notify the batch processor that the files are being added. This is to allow source controlled file systems // to manage previously uninstalled files. batchProcessor.BeginProcessing(files.Select(p => p.Path), PackageAction.Install); } string packageDirectory = PathResolver.GetPackageDirectory(package); // Add files FileSystem.AddFiles(files, packageDirectory); ExpandSatellitePackageFiles(package); } finally { if (batchProcessor != null) { batchProcessor.EndProcessing(); } } }
private void ExpandFiles(IPackage package) { string packageDirectory = PathResolver.GetPackageDirectory(package); // Add files files FileSystem.AddFiles(package.GetFiles(), packageDirectory); }
protected void ExpandSatellitePackageFiles(IPackage package) { // If this is a Satellite Package, then copy the satellite files into the related runtime package folder too IPackage runtimePackage; if (PackageHelper.IsSatellitePackage(package, LocalRepository, targetFramework: null, runtimePackage: out runtimePackage)) { var satelliteFiles = package.GetSatelliteFiles(); var runtimePath = PathResolver.GetPackageDirectory(runtimePackage); FileSystem.AddFiles(satelliteFiles, runtimePath); } }
private void ExpandFiles(IPackage package) { var batchProcessor = FileSystem as IBatchProcessor <string>; try { var files = package.GetFiles().ToList(); if (batchProcessor != null) { // Notify the batch processor that the files are being added. This is to allow source controlled file systems // to manage previously uninstalled files. batchProcessor.BeginProcessing(files.Select(p => p.Path), PackageAction.Install); } string packageDirectory = PathResolver.GetPackageDirectory(package); // Add files FileSystem.AddFiles(files, packageDirectory); // If this is a Satellite Package, then copy the satellite files into the related runtime package folder too IPackage runtimePackage; if (PackageHelper.IsSatellitePackage(package, LocalRepository, targetFramework: null, runtimePackage: out runtimePackage)) { var satelliteFiles = package.GetSatelliteFiles(); var runtimePath = PathResolver.GetPackageDirectory(runtimePackage); FileSystem.AddFiles(satelliteFiles, runtimePath); } } finally { if (batchProcessor != null) { batchProcessor.EndProcessing(); } } }