Skip to content

Commit 96f868f

Browse files
bvangrinsvenmartin9700
authored andcommitted
Updated readme (#5)
* Update README.md Updated formatting to show content properly * Update README.md Additional
1 parent d449a84 commit 96f868f

1 file changed

Lines changed: 44 additions & 56 deletions

File tree

README.md

Lines changed: 44 additions & 56 deletions
Original file line numberDiff line numberDiff line change
@@ -1,28 +1,25 @@
11
[![Build status](https://ci.appveyor.com/api/projects/status/7w0yl0tn1ut71cek?svg=true)](https://ci.appveyor.com/project/MartinPugh/psmodulebuild)
22

3-
#TOPIC
4-
Building PowerShell Modules with PSModuleBuild
3+
# TOPIC
54

6-
#SHORT DESCRIPTION
7-
Creating a PowerShell module can be hard, and maintaining it can be even harder. PSModuleBuild has been designed to make
8-
both tasks easier. In short, you put all of your advanced functions into individual .ps1 files and then invoke PSModuleBuild
9-
and let it collect all the functions into a PowerShell module file (.psm1) and create the PowerShell module manifest
10-
file (.psd1).
5+
Building PowerShell Modules with PSModuleBuild
6+
7+
# SHORT DESCRIPTION
8+
Creating a PowerShell module can be hard, and maintaining it can be even harder. PSModuleBuild has been designed to make both tasks easier. In short, you put all of your advanced functions into individual .ps1 files and then invoke PSModuleBuild and let it collect all the functions into a PowerShell module file (.psm1) and create the PowerShell module manifest file (.psd1).
119

12-
#DETAILED DESCRIPTION
10+
# DETAILED DESCRIPTION
1311

14-
Installation
15-
============
16-
Use the PowerShell Gallery to install PSModuleBuild:
12+
Installation
13+
============
14+
Use the PowerShell Gallery to install PSModuleBuild:
1715

1816
Install-Module PSModuleBuild
1917
Import-Module PSModuleBuild
2018

2119

22-
Continuous Integration/Continuous Deployment Support
23-
====================================================
24-
I tried to make PSModuleBuild friendly to CI/CD, specifically some of the community accepted standards for CI like
25-
Pester, Psake, etc. by putting in a filter that excludes files with certain keywords in them:
20+
Continuous Integration/Continuous Deployment Support
21+
====================================================
22+
I tried to make PSModuleBuild friendly to CI/CD, specifically some of the community accepted standards for CI like Pester, Psake, etc. by putting in a filter that excludes files with certain keywords in them:
2623

2724
exclude
2825
tests
@@ -31,32 +28,28 @@
3128
\.psdeploy\.
3229

3330

34-
Include.txt
35-
===========
36-
If you have any scripts or cmdlets that need to be run at Import-Module time, you can put them in an Include.txt
37-
file and PSModuleBuild will read this file first and put it in the module file first. This is not strictly needed
38-
as PSModuleBuild will read in all .ps1 files and put them in but if you'd like to make sure these commands are run at
39-
the beginning of the file you can.
31+
Include.txt
32+
===========
33+
If you have any scripts or cmdlets that need to be run at Import-Module time, you can put them in an Include.txt file and PSModuleBuild will read this file first and put it in the module file first. This is not strictly needed as PSModuleBuild will read in all .ps1 files and put them in but if you'd like to make sure these commands are run at the beginning of the file you can.
4034

41-
Public/Private Functions
42-
========================
43-
PSModuleBuild will support public and private functions as well. In your project folder create a Public folder and a Private
44-
folder and place your function files appropriately.
35+
Public/Private Functions
36+
========================
37+
PSModuleBuild will support public and private functions as well. In your project folder create a Public folder and a Private folder and place your function files appropriately.
4538

4639

47-
#EXAMPLES
48-
Simple
49-
------
50-
Create a folder, put your function files in it.
40+
# EXAMPLES
41+
42+
Simple
43+
------
44+
Create a folder, put your function files in it.
5145

5246
Invoke-PSModuleBuild -Path c:\YourModule
5347

54-
This will read all of the function files in c:\YourModule and create a module named after the folder (YourModule).
48+
This will read all of the function files in c:\YourModule and create a module named after the folder (YourModule).
5549

56-
57-
Intermediate
58-
------------
59-
Same as simple, but you want to put more information in:
50+
Intermediate
51+
------------
52+
Same as simple, but you want to put more information in:
6053

6154
$BuildSplat = @{
6255
Path = "c:\YourModule"
@@ -70,16 +63,12 @@
7063
}
7164
Invoke-PSModuleBuild @BuildSplat
7265

73-
This will create a new module, in a different location and fill the module manifest with the information. Invoke-PSModuleBuild
74-
supports all of the parameters from New-ModuleManifest.
66+
This will create a new module, in a different location and fill the module manifest with the information. Invoke-PSModuleBuild supports all of the parameters from New-ModuleManifest.
7567

7668

77-
Advanced - Additional supporting files
78-
--------------------------------------
79-
If you have about files, or additional XML descriptor files, PSModuleBuild will support that. First create a project folder,
80-
then create a source folder and place all of your function files in there. Now create another folder with the name of your
81-
module (we'll use NewModule in this example) and place your about files, and other files there, in the proper folder structure
82-
(en-US, etc).
69+
Advanced - Additional supporting files
70+
--------------------------------------
71+
If you have about files, or additional XML descriptor files, PSModuleBuild will support that. First create a project folder, then create a source folder and place all of your function files in there. Now create another folder with the name of your module (we'll use NewModule in this example) and place your about files, and other files there, in the proper folder structure (en-US, etc).
8372

8473
$BuildSplat = @{
8574
Path = "c:\ProjectFolder\Source"
@@ -94,10 +83,9 @@
9483
Invoke-PSModuleBuild @BuildSplat
9584

9685

97-
Advanced - Include source files in the module
98-
---------------------------------------------
99-
If you want to include the source function files in your module create a project folder, then create a folder with
100-
the name of your project and place all your function files (and other supporting files) in it.
86+
Advanced - Include source files in the module
87+
---------------------------------------------
88+
If you want to include the source function files in your module create a project folder, then create a folder with the name of your project and place all your function files (and other supporting files) in it.
10189

10290
$BuildSplat = @{
10391
Path = "c:\ProjectFolder\NewModule"
@@ -112,10 +100,9 @@
112100
Invoke-PSModuleBuild @BuildSplat
113101

114102

115-
Advanced - Mulitple Target Paths
116-
--------------------------------
117-
Need to deploy the module to multiple paths? Maybe you have a primary production location but also a process running
118-
in a DMZ?
103+
Advanced - Mulitple Target Paths
104+
--------------------------------
105+
Need to deploy the module to multiple paths? Maybe you have a primary production location but also a process running in a DMZ?
119106

120107
$BuildSplat = @{
121108
Path = "c:\ProjectFolder\NewModule\Source"
@@ -130,10 +117,11 @@
130117
Invoke-PSModuleBuild @BuildSplat
131118

132119

133-
#SEE ALSO
134-
Continuous Integration
135-
Continuous Deployment
136-
PSDeploy
137-
Psake
138-
PSScriptAnalyzer
120+
# SEE ALSO
121+
122+
Continuous Integration
123+
- Continuous Deployment
124+
- PSDeploy
125+
- Psake
126+
- PSScriptAnalyzer
139127

0 commit comments

Comments
 (0)