Skip to content

Commit 40c91d1

Browse files
Migrate ImportExport from generation to main (#20114)
* Move ImportExport to main * Update ChangeLog.md Co-authored-by: Lucas Yao <[email protected]>
1 parent 1cb1dd5 commit 40c91d1

File tree

253 files changed

+20469
-5325
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

253 files changed

+20469
-5325
lines changed

src/ImportExport/Az.ImportExport.format.ps1xml

Lines changed: 206 additions & 52 deletions
Large diffs are not rendered by default.

src/ImportExport/Az.ImportExport.psd1

Lines changed: 132 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,135 @@
1+
#
2+
# Module manifest for module 'Az.ImportExport'
3+
#
4+
# Generated by: Microsoft Corporation
5+
#
6+
# Generated on: 11/15/2022
7+
#
8+
19
@{
2-
GUID = '47cfc32b-a3bc-46e1-935e-11a63032bb86'
3-
RootModule = './Az.ImportExport.psm1'
4-
ModuleVersion = '0.1.0'
5-
CompatiblePSEditions = 'Core', 'Desktop'
6-
Author = 'Microsoft Corporation'
7-
CompanyName = 'Microsoft Corporation'
8-
Copyright = 'Microsoft Corporation. All rights reserved.'
9-
Description = 'Microsoft Azure PowerShell: ImportExport cmdlets'
10-
PowerShellVersion = '5.1'
11-
DotNetFrameworkVersion = '4.7.2'
12-
RequiredAssemblies = './bin/Az.ImportExport.private.dll'
13-
RequiredModules = @(@{ModuleName = 'Az.Accounts'; ModuleVersion = '2.7.4'; })
14-
FormatsToProcess = './Az.ImportExport.format.ps1xml'
15-
FunctionsToExport = 'Get-AzImportExport', 'Get-AzImportExportBitLockerKey', 'Get-AzImportExportLocation', 'New-AzImportExport', 'New-AzImportExportDriveListObject', 'Remove-AzImportExport', 'Update-AzImportExport'
16-
AliasesToExport = '*'
17-
PrivateData = @{
10+
11+
# Script module or binary module file associated with this manifest.
12+
RootModule = './Az.ImportExport.psm1'
13+
14+
# Version number of this module.
15+
ModuleVersion = '0.1.0'
16+
17+
# Supported PSEditions
18+
CompatiblePSEditions = 'Core', 'Desktop'
19+
20+
# ID used to uniquely identify this module
21+
GUID = '47cfc32b-a3bc-46e1-935e-11a63032bb86'
22+
23+
# Author of this module
24+
Author = 'Microsoft Corporation'
25+
26+
# Company or vendor of this module
27+
CompanyName = 'Microsoft Corporation'
28+
29+
# Copyright statement for this module
30+
Copyright = 'Microsoft Corporation. All rights reserved.'
31+
32+
# Description of the functionality provided by this module
33+
Description = 'Microsoft Azure PowerShell: ImportExport cmdlets'
34+
35+
# Minimum version of the PowerShell engine required by this module
36+
PowerShellVersion = '5.1'
37+
38+
# Name of the PowerShell host required by this module
39+
# PowerShellHostName = ''
40+
41+
# Minimum version of the PowerShell host required by this module
42+
# PowerShellHostVersion = ''
43+
44+
# Minimum version of Microsoft .NET Framework required by this module. This prerequisite is valid for the PowerShell Desktop edition only.
45+
DotNetFrameworkVersion = '4.7.2'
46+
47+
# Minimum version of the common language runtime (CLR) required by this module. This prerequisite is valid for the PowerShell Desktop edition only.
48+
# ClrVersion = ''
49+
50+
# Processor architecture (None, X86, Amd64) required by this module
51+
# ProcessorArchitecture = ''
52+
53+
# Modules that must be imported into the global environment prior to importing this module
54+
RequiredModules = @(@{ModuleName = 'Az.Accounts'; ModuleVersion = '2.7.4'; })
55+
56+
# Assemblies that must be loaded prior to importing this module
57+
RequiredAssemblies = './bin/Az.ImportExport.private.dll'
58+
59+
# Script files (.ps1) that are run in the caller's environment prior to importing this module.
60+
# ScriptsToProcess = @()
61+
62+
# Type files (.ps1xml) to be loaded when importing this module
63+
# TypesToProcess = @()
64+
65+
# Format files (.ps1xml) to be loaded when importing this module
66+
FormatsToProcess = './Az.ImportExport.format.ps1xml'
67+
68+
# Modules to import as nested modules of the module specified in RootModule/ModuleToProcess
69+
# NestedModules = @()
70+
71+
# Functions to export from this module, for best performance, do not use wildcards and do not delete the entry, use an empty array if there are no functions to export.
72+
FunctionsToExport = 'Get-AzImportExport', 'Get-AzImportExportBitLockerKey',
73+
'Get-AzImportExportLocation', 'New-AzImportExport',
74+
'New-AzImportExportDriveListObject', 'Remove-AzImportExport',
75+
'Update-AzImportExport'
76+
77+
# Cmdlets to export from this module, for best performance, do not use wildcards and do not delete the entry, use an empty array if there are no cmdlets to export.
78+
CmdletsToExport = @()
79+
80+
# Variables to export from this module
81+
# VariablesToExport = @()
82+
83+
# Aliases to export from this module, for best performance, do not use wildcards and do not delete the entry, use an empty array if there are no aliases to export.
84+
AliasesToExport = '*'
85+
86+
# DSC resources to export from this module
87+
# DscResourcesToExport = @()
88+
89+
# List of all modules packaged with this module
90+
# ModuleList = @()
91+
92+
# List of all files packaged with this module
93+
# FileList = @()
94+
95+
# Private data to pass to the module specified in RootModule/ModuleToProcess. This may also contain a PSData hashtable with additional module metadata used by PowerShell.
96+
PrivateData = @{
97+
1898
PSData = @{
19-
Tags = 'Azure', 'ResourceManager', 'ARM', 'PSModule', 'ImportExport'
20-
LicenseUri = 'https://aka.ms/azps-license'
21-
ProjectUri = 'https://github.com/Azure/azure-powershell'
22-
ReleaseNotes = ''
23-
}
24-
}
99+
100+
# Tags applied to this module. These help with module discovery in online galleries.
101+
Tags = 'Azure','ResourceManager','ARM','PSModule','ImportExport'
102+
103+
# A URL to the license for this module.
104+
LicenseUri = 'https://aka.ms/azps-license'
105+
106+
# A URL to the main website for this project.
107+
ProjectUri = 'https://github.com/Azure/azure-powershell'
108+
109+
# A URL to an icon representing this module.
110+
# IconUri = ''
111+
112+
# ReleaseNotes of this module
113+
# ReleaseNotes = ''
114+
115+
# Prerelease string of this module
116+
# Prerelease = ''
117+
118+
# Flag to indicate whether the module requires explicit user acceptance for install/update/save
119+
# RequireLicenseAcceptance = $false
120+
121+
# External dependent modules of this module
122+
# ExternalModuleDependencies = @()
123+
124+
} # End of PSData hashtable
125+
126+
} # End of PrivateData hashtable
127+
128+
# HelpInfo URI of this module
129+
# HelpInfoURI = ''
130+
131+
# Default prefix for commands exported from this module. Override the default prefix using Import-Module -Prefix.
132+
# DefaultCommandPrefix = ''
133+
25134
}
135+

src/ImportExport/Az.ImportExport.psm1

Lines changed: 22 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,17 @@
11
# region Generated
22
# ----------------------------------------------------------------------------------
3-
#
4-
# Copyright Microsoft Corporation
5-
# Licensed under the Apache License, Version 2.0 (the "License");
6-
# you may not use this file except in compliance with the License.
7-
# You may obtain a copy of the License at
8-
# http://www.apache.org/licenses/LICENSE-2.0
9-
# Unless required by applicable law or agreed to in writing, software
10-
# distributed under the License is distributed on an "AS IS" BASIS,
11-
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12-
# See the License for the specific language governing permissions and
13-
# limitations under the License.
3+
# Copyright (c) Microsoft Corporation. All rights reserved.
4+
# Licensed under the Apache License, Version 2.0 (the "License");
5+
# you may not use this file except in compliance with the License.
6+
# You may obtain a copy of the License at
7+
# http://www.apache.org/licenses/LICENSE-2.0
8+
# Unless required by applicable law or agreed to in writing, software
9+
# distributed under the License is distributed on an "AS IS" BASIS,
10+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11+
# See the License for the specific language governing permissions and
12+
# limitations under the License.
13+
# Code generated by Microsoft (R) AutoRest Code Generator.Changes may cause incorrect behavior and will be lost if the code
14+
# is regenerated.
1415
# ----------------------------------------------------------------------------------
1516
# Load required Az.Accounts module
1617
$accountsName = 'Az.Accounts'
@@ -24,17 +25,17 @@
2425
}
2526
}
2627
if(-not $accountsModule) {
27-
$hasAdequateVersion = (Get-Module -Name $accountsName -ListAvailable | Where-Object { $_.Version -ge [System.Version]'1.7.4' } | Measure-Object).Count -gt 0
28+
$hasAdequateVersion = (Get-Module -Name $accountsName -ListAvailable | Where-Object { $_.Version -ge [System.Version]'2.7.5' } | Measure-Object).Count -gt 0
2829
if($hasAdequateVersion) {
29-
$accountsModule = Import-Module -Name $accountsName -MinimumVersion 1.7.4 -Scope Global -PassThru
30+
$accountsModule = Import-Module -Name $accountsName -MinimumVersion 2.7.5 -Scope Global -PassThru
3031
}
3132
}
3233
}
3334

3435
if(-not $accountsModule) {
35-
Write-Error "`nThis module requires $accountsName version 1.7.4 or greater. For installation instructions, please see: https://docs.microsoft.com/en-us/powershell/azure/install-az-ps" -ErrorAction Stop
36-
} elseif (($accountsModule.Version -lt [System.Version]'1.7.4') -and (-not $localAccounts)) {
37-
Write-Error "`nThis module requires $accountsName version 1.7.4 or greater. An earlier version of Az.Accounts is imported in the current PowerShell session. If you are running test, please try to remove '.PSSharedModules' in your home directory. Otherwise please open a new PowerShell session and import this module again.`nAdditionally, this error could indicate that multiple incompatible versions of Azure PowerShell modules are installed on your system. For troubleshooting information, please see: https://aka.ms/azps-version-error" -ErrorAction Stop
36+
Write-Error "`nThis module requires $accountsName version 2.7.5 or greater. For installation instructions, please see: https://docs.microsoft.com/powershell/azure/install-az-ps" -ErrorAction Stop
37+
} elseif (($accountsModule.Version -lt [System.Version]'2.7.5') -and (-not $localAccounts)) {
38+
Write-Error "`nThis module requires $accountsName version 2.7.5 or greater. An earlier version of Az.Accounts is imported in the current PowerShell session. If you are running test, please try to add the switch '-RegenerateSupportModule' when executing 'test-module.ps1'. Otherwise please open a new PowerShell session and import this module again.`nAdditionally, this error could indicate that multiple incompatible versions of Azure PowerShell modules are installed on your system. For troubleshooting information, please see: https://aka.ms/azps-version-error" -ErrorAction Stop
3839
}
3940
Write-Information "Loaded Module '$($accountsModule.Name)'"
4041

@@ -49,7 +50,12 @@
4950

5051
# Tweaks the pipeline on module load
5152
$instance.OnModuleLoad = $VTable.OnModuleLoad
53+
54+
# Following two delegates are added for telemetry
55+
$instance.GetTelemetryId = $VTable.GetTelemetryId
56+
$instance.Telemetry = $VTable.Telemetry
5257

58+
5359
# Tweaks the pipeline per call
5460
$instance.OnNewRequest = $VTable.OnNewRequest
5561

src/ImportExport/ChangeLog.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@
1818
- Additional information about change #1
1919
-->
2020
## Upcoming Release
21+
* Upgraded API version to 2021-01-01
2122

2223
## Version 0.1.0
2324
* the first preview release

0 commit comments

Comments
 (0)