You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: tools/AzDev/README.md
+32-3Lines changed: 32 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -4,6 +4,16 @@ This module is designed to help developers of Azure PowerShell modules. It provi
4
4
5
5
All the cmdlets in this module are prefixed with `Dev-` to avoid conflicts with other modules.
6
6
7
+
-[Quick start](#quick-start)
8
+
-[Features](#features)
9
+
-[Repo inventory](#repo-inventory)
10
+
-[Connect azure-powershell and azure-powershell-common](#connect-azure-powershell-and-azure-powershell-common)
11
+
-[Autorest helper](#autorest-helper)
12
+
-[Open swagger online](#open-swagger-online)
13
+
-[Development](#development)
14
+
-[Design](#design)
15
+
-[Testing](#testing)
16
+
7
17
## Quick start
8
18
9
19
```powershell
@@ -56,10 +66,10 @@ Help you connect the azure-powershell and azure-powershell-common repositories f
56
66
57
67
```powershell
58
68
# Connect
59
-
Connect-CommonRepo
69
+
Connect-DevCommonRepo
60
70
61
71
# Disconnect
62
-
Disconnect-CommonRepo
72
+
Disconnect-DevCommonRepo
63
73
```
64
74
65
75
### Autorest helper
@@ -81,4 +91,23 @@ Multiple swagger references found in [SapVirtualInstance.Autorest]
81
91
Enter the number corresponding to your selection
82
92
1
83
93
Opening https://github.com/Azure/azure-rest-api-specs/blob/202321f386ea5b0c103b46902d43b3d3c50e029c/specification/workloads/resource-manager/Microsoft.Workloads/SAPVirtualInstance/readme.md in default browser...
84
-
```
94
+
```
95
+
96
+
## Development
97
+
98
+
### Design
99
+
100
+
`AzDev` supports both C# based and script based cmdlets.
101
+
102
+
The script based cmdlets are located in the `AzDev` folder. Take a look at `AzDev/CommonRepo.psm1` for example. Update `NestedModules` in `AzDev.psd1` when you add new scripts.
103
+
104
+
The C# based cmdlets are located in the `src` folder. It's quite similar to developing a SDK-based module in Azure PowerShell.
105
+
106
+
Either way, make sure
107
+
108
+
1. All cmdlets are prefixed with `Dev-`.
109
+
2. Add your new cmdlets to `FunctionsToExport` or `CmdletsToExport` in `AzDev.psd1`.
110
+
111
+
### Testing
112
+
113
+
Use `dotnet test` to run the unit tests. `Invoke-Pester` to run the E2E tests located in `Tests/PSTests`.
0 commit comments