Import-HubContext

Synopsis

Import a PSHubContext from a .json file at the path received.

Syntax

Secure Password

Import-HubContext -Path <string> -SecurePassword [<CommonParameters>]

Password

Import-HubContext -Path <string> [-Password <string>] [<CommonParameters>]

Description

Import a PSHubContext from a .json file at the path received. If SecurePassword is provided, prompt to enter a password to decrypt the .json file. If Password provided, decrypt the .json file with the password received.

Examples

Example 1

PS C:\> Import-HubContext -Path "C:\PATH\TO\YOUR\FILE\file.json"

Import a standard PSHubContext.

Example 2

PS C:\> Import-HubContext -Path "C:\PATH\TO\YOUR\FILEile.json" -Password "password"

Import the PSHubContext from a file protected by a password.

Example 3

PS C:\> Import-HubContext -Path "C:\PATH\TO\YOUR\FILEile.json" -SecurePassword

Import the PSHubContext from a file protected by a password. The user will be prompted for the password.

Parameters

-Password

Will decrypt the file with the clear password

Type: System.String
DefaultValue: ''
SupportsWildcards: false
Aliases: []
ParameterSets:
- Name: Password
  Position: Named
  IsRequired: false
  ValueFromPipeline: false
  ValueFromPipelineByPropertyName: false
  ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''

-Path

The file path of Hub context to import.

Type: System.String
DefaultValue: ''
SupportsWildcards: false
Aliases: []
ParameterSets:
- Name: (All)
  Position: Named
  IsRequired: true
  ValueFromPipeline: false
  ValueFromPipelineByPropertyName: false
  ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''

-SecurePassword

Will prompt the password to decrypt the file with

Type: System.Management.Automation.SwitchParameter
DefaultValue: ''
SupportsWildcards: false
Aliases: []
ParameterSets:
- Name: Secure Password
  Position: Named
  IsRequired: true
  ValueFromPipeline: false
  ValueFromPipelineByPropertyName: false
  ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''

CommonParameters

This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, -ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.

Notes

For more information, type "Get-Help Import-HubContext -detailed". For technical information, type "Get-Help Import-HubContext -full".

Devolutions Forum logo Donnez-nous vos commentaires