Create a report from a repository directory


New-RepositoryReport [[-Format] <String>] [[-RepositoryPath] <DirectoryInfo>] [[-OutputFile] <FileInfo>] [<CommonParameters>]


This function scans a repository (or any directory containing CVAs and EXEs) and creates a report in one of the supported formats.

Currently the supported formats are:

  • XML - Return an XML object
  • JSON - Return a JSON document
  • CSV - Return a CSV document
  • ExcelCSV - Return a CSV document containing an Excel hint that defines comma as a default separator. Use this only if you plan on opening the CSV file with Excel.

If a format is not specified, the function will return PowerShell objects to the pipeline.


Name Argument Description
Format <String> Specify the output format (CSV, JSON, or XML). If not specified, the function will return PowerShell objects.
RepositoryPath <DirectoryInfo> By default, the function assumes the repository is in the current directory. This parameter allows specifying a different location for the repository.
OutputFile <FileInfo> Specify an output file for the function. Can only be specified together with "Format".


The function currently supports scenarios where the SoftPaq executable is stored under the format sp.exe.


PS C:\> New-RepositoryReport -Format JSON -RepositoryPath c:\myrepository\softpaqs -OutputFile c:\repository\today.json