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: README.md
+13-8Lines changed: 13 additions & 8 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -45,8 +45,9 @@ All the Module files should be in inside `src` folder
45
45
│ └── New-PublicFunction.ps1
46
46
├── resources
47
47
│ └── some-config.json
48
-
└── tests
49
-
└── Pester.Some.Tests.ps1
48
+
└── classes
49
+
└── Person.classes.ps1
50
+
└── Person.enums.ps1
50
51
```
51
52
52
53
### Dist Folder
@@ -71,6 +72,7 @@ Run `New-MTModule` to generate the scaffolding; this will also create the `proje
71
72
- Place all your functions in the `private` and `public` folders within the `src` directory.
72
73
- All functions in the `public` folder are exported during the module build.
73
74
- All functions in the `private` folder are accessible internally within the module but are not exposed outside the module.
75
+
- All `ps1` files in `classes` folder contains classes and enums, that are processed and placed in topmost of generated `psm1` files
74
76
- Contents of the `src/resources` folder will be handled based on setting `copyResourcesToModuleRoot`
75
77
76
78
#### Resources Folder
@@ -149,12 +151,15 @@ All the pester configurations are stored in `project.json`, simply run `Invoke-M
149
151
150
152
A simple command to update the module version by modifying the values in `project.json`. You can also manually edit the file in your favorite editor. This command makes it easy to update the semantic version.
151
153
152
-
- Running `Update-MTModuleVersion` without any parameters will update the patch version (e.g., 1.0.1 -> 1.0.2).
153
-
- Running `Update-MTModuleVersion -Label Major` updates the major version (e.g., 1.0.1 -> 2.0.1).
154
-
- Running `Update-MTModuleVersion -Label Minor` updates the minor version (e.g., 1.0.1 -> 1.1.1).
154
+
- Running `Update-MTModuleVersion` without any parameters will update the patch version (e.g., 1.2.3 -> 1.2.4)
155
+
- Running `Update-MTModuleVersion -Label Major` updates the major version and resets Minor, Patch to 0 (e.g., 1.2.1 -> 2.0.0)
156
+
- Running `Update-MTModuleVersion -Label Minor` updates the minor version and resets Patch to 0 (e.g., 1.2.3 -> 1.3.0)
155
157
156
158
## Advanced - Use it in Github Actions
157
159
160
+
> [!TIP]
161
+
> This repository uses Github actions to run tests and publish to PowerShell Gallery, use it as reference.
162
+
158
163
This is not required for local module builds, if you are running github actions, use the following yaml workflow template to test, build and publish module which helps to automate the process of:
159
164
160
165
1. Checking out the repository code.
@@ -202,12 +207,12 @@ jobs:
202
207
203
208
## 📝 Requirement
204
209
205
-
- Only tested on PowerShell 7.4, most likely wont work on 5.1
206
-
- No depenedencies. This module doesn’t depend on any other module.
210
+
- Only tested on PowerShell 7.4, ~most likely~ will not work on 5.1. Underlying module can still support older version, only the ModuleTools builder wont work on older version.
211
+
- No depenedencies. This module doesn’t depend on any other module. Completely self contained
Copy file name to clipboardExpand all lines: project.json
+1-1Lines changed: 1 addition & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -1,7 +1,7 @@
1
1
{
2
2
"ProjectName": "ModuleTools",
3
3
"Description": "ModuleTools is a versatile, standalone PowerShell module builder. Create anything from simple to robust modules with ease. Built for CICD and Automation.",
0 commit comments