Chocolatey Packages

Documentation about My Chocolatey Packages.

View project on GitHub

Get-ChocolateyIsoFile

Copies a single file from an ISO to a destination on disk.

Syntax

Get-ChocolateyIsoFile `
  -isoFile <String> `
  -filePath <String> `
  -destination <String> `
  [-filePath64 <String>] `
  [-packageName <String>] `
  [-disableLogging] `
  [-ignoredArguments <Object[]>] [<CommonParameters>]

Description

Mounts the specified ISO using built-in PowerShell cmdlets, selects the appropriate 32-bit or 64-bit file path, and copies that file to the destination. This does not rely on 7-Zip or any other external tooling.

Notes

This command will assert UAC/Admin privileges on the machine because it uses Mount-DiskImage.

Aliases

None

Examples

EXAMPLE 1

$toolsDir = "$(Split-Path -Parent $MyInvocation.MyCommand.Definition)"
Get-ChocolateyIsoFile -IsoFile "$toolsDir\\image.iso" `
                      -FilePath 'setup.msi' `
                      -Destination $toolsDir

Inputs

None

Outputs

  • Returns the destination path of the copied file.

Parameters

-isoFile <String>

Full path to the ISO file to mount.

Property Value
Aliases  
Required? true
Position? 1
Default Value  
Accept Pipeline Input? false

-filePath <String>

Relative path of the file inside the ISO to copy for 32-bit systems.

Property Value
Aliases file
Required? true
Position? 2
Default Value  
Accept Pipeline Input? false

-destination <String>

Path to copy the file to. If this points to an existing directory (or ends with a path separator), the file name from FilePath is used.

Property Value
Aliases destinationPath
Required? true
Position? 3
Default Value  
Accept Pipeline Input? false

-filePath64 [<String>]

Relative path of the file inside the ISO to copy for 64-bit systems. If provided on a 64-bit system, this file is used instead of FilePath.

Property Value
Aliases file64
Required? false
Position? named
Default Value  
Accept Pipeline Input? false

-packageName [<String>]

OPTIONAL - Used to log the copied file path alongside other Chocolatey package activity.

Property Value
Aliases  
Required? false
Position? 4
Default Value  
Accept Pipeline Input? false

-disableLogging

OPTIONAL - Disables logging of the copied file.

Property Value
Aliases  
Required? false
Position? named
Default Value False
Accept Pipeline Input? false

-ignoredArguments [<Object[]>]

Allows splatting with arguments that do not apply. Do not use directly.

Property Value
Aliases  
Required? false
Position? named
Default Value  
Accept Pipeline Input? false

<CommonParameters>

This cmdlet supports the common parameters. For more information, see about_CommonParameters.

Extension documentation

NOTE: This documentation has been automatically generated using:

$extensionPath = Join-Path $env:ChocolateyInstall 'extensions\chocolatey-isomount'
Import-Module (Join-Path $extensionPath 'chocolatey-isomount.psm1') -Force
Get-Help Get-ChocolateyIsoFile -Full

View the source for Get-ChocolateyIsoFile