-
Notifications
You must be signed in to change notification settings - Fork 4k
[DO NOT REVIEW] Az.fileshares 2025 06 01 autogenerated from tyespec #28345
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
ankushbindlish2
wants to merge
7
commits into
Azure:main
Choose a base branch
from
ankushbindlish2:az.fileshares-2025-06-01
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from 4 commits
Commits
Show all changes
7 commits
Select commit
Hold shift + click to select a range
cc168bc
Changes with a test
ankushbindlish2 4758324
Merge branch 'main' into main
ankushbindlish2 f5d385e
Merge branch 'Azure:main' into main
ankushbindlish2 1cbe28a
Sample Typespec to powershell
ankushbindlish2 6343d9f
more files
ankushbindlish2 5c6a7f5
revert
ankushbindlish2 7b013e3
Update
ankushbindlish2 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
* text=auto |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
bin | ||
obj | ||
.vs | ||
generated | ||
internal | ||
exports | ||
tools | ||
test/*-TestResults.xml | ||
license.txt | ||
/*.ps1 | ||
/*.psd1 | ||
/*.ps1xml | ||
/*.psm1 | ||
/*.snk | ||
/*.csproj | ||
/*.nuspec |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
<Project Sdk="Microsoft.NET.Sdk"> | ||
|
||
<PropertyGroup> | ||
<Version>0.1.0</Version> | ||
<LangVersion>7.1</LangVersion> | ||
<TargetFramework>netstandard2.0</TargetFramework> | ||
<OutputType>Library</OutputType> | ||
<AssemblyName>Az.FileShare.private</AssemblyName> | ||
<GenerateAssemblyInfo>false</GenerateAssemblyInfo> | ||
<RootNamespace>Microsoft.Azure.PowerShell.Cmdlets.FileShare</RootNamespace> | ||
<CopyLocalLockFileAssemblies>true</CopyLocalLockFileAssemblies> | ||
<AppendTargetFrameworkToOutputPath>false</AppendTargetFrameworkToOutputPath> | ||
<OutputPath>./bin</OutputPath> | ||
<PublishDir>$(OutputPath)</PublishDir> | ||
<NuspecFile>Az.FileShare.nuspec</NuspecFile> | ||
<NoPackageAnalysis>true</NoPackageAnalysis> | ||
<!-- Some methods are marked async and don't have an await in them --> | ||
<!-- warning CS1591: Missing XML comment for publicly visible type or member --> | ||
<NoWarn>1998, 1591</NoWarn> | ||
<TreatWarningsAsErrors>true</TreatWarningsAsErrors> | ||
<WarningsAsErrors /> | ||
</PropertyGroup> | ||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'"> | ||
<DelaySign>false</DelaySign> | ||
<DefineConstants>TRACE;DEBUG;NETSTANDARD</DefineConstants> | ||
</PropertyGroup> | ||
|
||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|AnyCPU'"> | ||
<SignAssembly>true</SignAssembly> | ||
<DelaySign>true</DelaySign> | ||
<AssemblyOriginatorKeyFile>MSSharedLibKey.snk</AssemblyOriginatorKeyFile> | ||
<DefineConstants>TRACE;RELEASE;NETSTANDARD;SIGN</DefineConstants> | ||
</PropertyGroup> | ||
|
||
<ItemGroup> | ||
<PackageReference Include="PowerShellStandard.Library" Version="5.1.0" /> | ||
<PackageReference Include="Microsoft.CSharp" Version="4.4.1" /> | ||
</ItemGroup> | ||
|
||
<PropertyGroup> | ||
<DefaultItemExcludes>$(DefaultItemExcludes);resources/**</DefaultItemExcludes> | ||
</PropertyGroup> | ||
|
||
</Project> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<package xmlns="http://schemas.microsoft.com/packaging/2013/05/nuspec.xsd"> | ||
<metadata> | ||
<id>Az.FileShare</id> | ||
<version>0.1.0</version> | ||
<authors>Microsoft Corporation</authors> | ||
<owners>Microsoft Corporation</owners> | ||
<requireLicenseAcceptance>true</requireLicenseAcceptance> | ||
<licenseUrl>https://aka.ms/azps-license</licenseUrl> | ||
<projectUrl>https://github.com/Azure/azure-powershell</projectUrl> | ||
<description>Microsoft Azure PowerShell: FileShare cmdlets</description> | ||
<releaseNotes></releaseNotes> | ||
<copyright>Microsoft Corporation. All rights reserved.</copyright> | ||
<tags>Azure ResourceManager ARM PSModule FileShare</tags> | ||
<dependencies> | ||
<dependency id="Az.Accounts" version="2.7.5" /> | ||
</dependencies> | ||
</metadata> | ||
<files> | ||
<file src="Az.FileShare.format.ps1xml" /> | ||
<file src="Az.FileShare.psd1" /> | ||
<file src="Az.FileShare.psm1" /> | ||
<!-- https://github.com/NuGet/Home/issues/3584 --> | ||
<file src="bin/Az.FileShare.private.dll" target="bin" /> | ||
<file src="bin\Az.FileShare.private.deps.json" target="bin" /> | ||
<file src="internal\**\*.*" exclude="internal\README.md" target="internal" /> | ||
<file src="custom\**\*.*" exclude="custom\README.md;custom\**\*.cs" target="custom" /> | ||
<file src="docs\**\*.md" exclude="docs\README.md" target="docs" /> | ||
<file src="exports\**\ProxyCmdletDefinitions.ps1" target="exports" /> | ||
<file src="utils\**\*.*" target="utils" /> | ||
</files> | ||
</package> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,119 @@ | ||
# region Generated | ||
# ---------------------------------------------------------------------------------- | ||
# Copyright (c) Microsoft Corporation. All rights reserved. | ||
# Licensed under the Apache License, Version 2.0 (the "License"); | ||
# you may not use this file except in compliance with the License. | ||
# You may obtain a copy of the License at | ||
# http://www.apache.org/licenses/LICENSE-2.0 | ||
# Unless required by applicable law or agreed to in writing, software | ||
# distributed under the License is distributed on an "AS IS" BASIS, | ||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
# See the License for the specific language governing permissions and | ||
# limitations under the License. | ||
# Code generated by Microsoft (R) AutoRest Code Generator.Changes may cause incorrect behavior and will be lost if the code | ||
# is regenerated. | ||
# ---------------------------------------------------------------------------------- | ||
# Load required Az.Accounts module | ||
$accountsName = 'Az.Accounts' | ||
$accountsModule = Get-Module -Name $accountsName | ||
if(-not $accountsModule) { | ||
$localAccountsPath = Join-Path $PSScriptRoot 'generated\modules' | ||
if(Test-Path -Path $localAccountsPath) { | ||
$localAccounts = Get-ChildItem -Path $localAccountsPath -Recurse -Include 'Az.Accounts.psd1' | Select-Object -Last 1 | ||
if($localAccounts) { | ||
$accountsModule = Import-Module -Name ($localAccounts.FullName) -Scope Global -PassThru | ||
} | ||
} | ||
if(-not $accountsModule) { | ||
$hasAdequateVersion = (Get-Module -Name $accountsName -ListAvailable | Where-Object { $_.Version -ge [System.Version]'2.7.5' } | Measure-Object).Count -gt 0 | ||
if($hasAdequateVersion) { | ||
$accountsModule = Import-Module -Name $accountsName -MinimumVersion 2.7.5 -Scope Global -PassThru | ||
} | ||
} | ||
} | ||
|
||
if(-not $accountsModule) { | ||
Write-Error "`nThis module requires $accountsName version 2.7.5 or greater. For installation instructions, please see: https://learn.microsoft.com/powershell/azure/install-az-ps" -ErrorAction Stop | ||
} elseif (($accountsModule.Version -lt [System.Version]'2.7.5') -and (-not $localAccounts)) { | ||
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 | ||
} | ||
Write-Information "Loaded Module '$($accountsModule.Name)'" | ||
|
||
# Load the private module dll | ||
$null = Import-Module -Name (Join-Path $PSScriptRoot './bin/Az.FileShare.private.dll') | ||
|
||
# Get the private module's instance | ||
$instance = [Microsoft.Azure.PowerShell.Cmdlets.FileShare.Module]::Instance | ||
|
||
# Ask for the shared functionality table | ||
$VTable = Register-AzModule | ||
|
||
# Tweaks the pipeline on module load | ||
$instance.OnModuleLoad = $VTable.OnModuleLoad | ||
|
||
# Following two delegates are added for telemetry | ||
$instance.GetTelemetryId = $VTable.GetTelemetryId | ||
$instance.Telemetry = $VTable.Telemetry | ||
|
||
# Delegate to sanitize the output object | ||
$instance.SanitizeOutput = $VTable.SanitizerHandler | ||
|
||
# Delegate to get the telemetry info | ||
$instance.GetTelemetryInfo = $VTable.GetTelemetryInfo | ||
|
||
# Tweaks the pipeline per call | ||
$instance.OnNewRequest = $VTable.OnNewRequest | ||
|
||
# Gets shared parameter values | ||
$instance.GetParameterValue = $VTable.GetParameterValue | ||
|
||
# Allows shared module to listen to events from this module | ||
$instance.EventListener = $VTable.EventListener | ||
|
||
# Gets shared argument completers | ||
$instance.ArgumentCompleter = $VTable.ArgumentCompleter | ||
|
||
# The name of the currently selected Azure profile | ||
$instance.ProfileName = $VTable.ProfileName | ||
|
||
# Load the custom module | ||
$customModulePath = Join-Path $PSScriptRoot './custom/Az.FileShare.custom.psm1' | ||
if(Test-Path $customModulePath) { | ||
$null = Import-Module -Name $customModulePath | ||
} | ||
|
||
# Export nothing to clear implicit exports | ||
Export-ModuleMember | ||
|
||
# Export proxy cmdlet scripts | ||
$exportsPath = Join-Path $PSScriptRoot './exports' | ||
$directories = Get-ChildItem -Directory -Path $exportsPath | ||
$profileDirectory = $null | ||
if($instance.ProfileName) { | ||
if(($directories | ForEach-Object { $_.Name }) -contains $instance.ProfileName) { | ||
$profileDirectory = $directories | Where-Object { $_.Name -eq $instance.ProfileName } | ||
} else { | ||
# Don't export anything if the profile doesn't exist for the module | ||
$exportsPath = $null | ||
Write-Warning "Selected Azure profile '$($instance.ProfileName)' does not exist for module '$($instance.Name)'. No cmdlets were loaded." | ||
} | ||
} elseif(($directories | Measure-Object).Count -gt 0) { | ||
# Load the last folder if no profile is selected | ||
$profileDirectory = $directories | Select-Object -Last 1 | ||
} | ||
|
||
if($profileDirectory) { | ||
Write-Information "Loaded Azure profile '$($profileDirectory.Name)' for module '$($instance.Name)'" | ||
$exportsPath = $profileDirectory.FullName | ||
} | ||
|
||
if($exportsPath) { | ||
Get-ChildItem -Path $exportsPath -Recurse -Include '*.ps1' -File | ForEach-Object { . $_.FullName } | ||
$cmdletNames = Get-ScriptCmdlet -ScriptFolder $exportsPath | ||
Export-ModuleMember -Function $cmdletNames -Alias (Get-ScriptCmdlet -ScriptFolder $exportsPath -AsAlias) | ||
} | ||
|
||
# Finalize initialization of this module | ||
$instance.Init(); | ||
Write-Information "Loaded Module '$($instance.Name)'" | ||
# endregion |
Binary file not shown.
29 changes: 29 additions & 0 deletions
29
src/FileShare/FileShare.Autorest/Properties/AssemblyInfo.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
// Copyright (c) Microsoft Corporation. All rights reserved. | ||
// Licensed under the MIT License. See License.txt in the project root for license information. | ||
// Changes may cause incorrect behavior and will be lost if the code is regenerated. | ||
// Copyright (c) Microsoft Corporation. All rights reserved. | ||
// Licensed under the Apache License, Version 2.0 (the ""License""); | ||
// you may not use this file except in compliance with the License. | ||
// You may obtain a copy of the License at | ||
// http://www.apache.org/licenses/LICENSE-2.0 | ||
// Unless required by applicable law or agreed to in writing, software | ||
// distributed under the License is distributed on an ""AS IS"" BASIS, | ||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
// See the License for the specific language governing permissions and | ||
// limitations under the License. | ||
// Code generated by Microsoft (R) AutoRest Code Generator.Changes may cause incorrect behavior and will be lost if the code | ||
// is regenerated. | ||
|
||
using System; | ||
using System.Reflection; | ||
using System.Runtime.CompilerServices; | ||
using System.Runtime.InteropServices; | ||
|
||
[assembly: System.Reflection.AssemblyCompanyAttribute("Microsoft")] | ||
[assembly: System.Reflection.AssemblyCopyrightAttribute("Copyright © Microsoft")] | ||
[assembly: System.Reflection.AssemblyProductAttribute("Microsoft Azure PowerShell")] | ||
[assembly: System.Reflection.AssemblyTitleAttribute("Microsoft Azure PowerShell - MicrosoftFileShares")] | ||
[assembly: System.Reflection.AssemblyFileVersionAttribute("0.1.0.0")] | ||
[assembly: System.Reflection.AssemblyVersionAttribute("0.1.0.0")] | ||
[assembly: System.Runtime.InteropServices.ComVisibleAttribute(false)] | ||
[assembly: System.CLSCompliantAttribute(false)] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
<!-- region Generated --> | ||
# Az.FileShare | ||
This directory contains the PowerShell module for the FileShare service. | ||
|
||
--- | ||
## Info | ||
- Modifiable: yes | ||
- Generated: all | ||
- Committed: yes | ||
- Packaged: yes | ||
|
||
--- | ||
## Detail | ||
This module was primarily generated via [AutoRest](https://github.com/Azure/autorest) using the [PowerShell](https://github.com/Azure/autorest.powershell) extension. | ||
|
||
## Module Requirements | ||
- [Az.Accounts module](https://www.powershellgallery.com/packages/Az.Accounts/), version 2.7.5 or greater | ||
|
||
## Authentication | ||
AutoRest does not generate authentication code for the module. Authentication is handled via Az.Accounts by altering the HTTP payload before it is sent. | ||
|
||
## Development | ||
For information on how to develop for `Az.FileShare`, see [how-to.md](how-to.md). | ||
<!-- endregion --> |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Missing space before 'Changes' in the comment. Should be '# Code generated by Microsoft (R) AutoRest Code Generator. Changes may cause incorrect behavior and will be lost if the code'
Copilot uses AI. Check for mistakes.