Skip to content

Commit 8578c67

Browse files
committed
Fixed problem with spaces in exe path
Added README file with project description Updated module version
1 parent be78dfd commit 8578c67

File tree

3 files changed

+39
-4
lines changed

3 files changed

+39
-4
lines changed

README.md

+36
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,38 @@
11
# WebPI Power Shell
22

3+
**WebPI Power Shell** is a wrapper for **WebPICMD.exe** written in PowerShell and shipped as Powershell Module
4+
5+
**WebPICMD.exe**([WebPI Command line](https://docs.microsoft.com/en-us/iis/install/web-platform-installer/web-platform-installer-v4-command-line-webpicmdexe-rtw-release#using-webpicmdexe)) is a command line tool for managing **Web Platform Installer**
6+
7+
The **Microsoft Web Platform Installer (Web PI)** is a free tool that makes getting the latest components of the Microsoft Web Platform, including Internet Information Services (IIS), SQL Server Express, .NET Framework and Visual Web Developer easy
8+
9+
10+
# Installation
11+
Module is available on [Powershell Gallery](https://www.powershellgallery.com/packages/WebPI.PS/)
12+
13+
### Inspect
14+
```powershell
15+
PS> Save-Module -Name WebPI.PS -Path <path>
16+
```
17+
### Install
18+
```powershell
19+
PS> Install-Module -Name WebPI.PS
20+
```
21+
22+
# Usage
23+
24+
```powershell
25+
PS> Import-Module WebPI.PS
26+
PS> Invoke-WebPI /Install /Products:UrlRewrite2
27+
```
28+
29+
**Limitations**
30+
31+
Due to the fact how PS split parameter if there is a comma in it, use double quote so whole string will be treated as a single param.
32+
33+
```diff
34+
- BAD
35+
- Invoke-WebPI /Install /Products:UrlRewrite2,WDeploy36
36+
+ GOOD
37+
+ Invoke-WebPI /Install "/Products:UrlRewrite2,WDeploy36"
38+
```

WebPI.PS.psd1

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
RootModule = 'WebPI.PS.psm1'
55

66
# Version number of this module.
7-
ModuleVersion = '1.0.1'
7+
ModuleVersion = '1.1.0'
88

99
# ID used to uniquely identify this module
1010
GUID = 'add2ca98-860b-4313-9ad1-9ef90884e6ca'

WebPI.PS.psm1

+2-3
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,8 @@ function Get-CurrentModulePath () {
1010

1111
function Invoke-WebPI () {
1212
$CurrentModulePath = Get-CurrentModulePath
13-
$arguments = $args -join ' '
14-
$CurrentModulePath = $CurrentModulePath.Replace(" ", "^ ")
15-
cmd /c "$CurrentModulePath\webpi\WebpiCmd.exe $arguments"
13+
$arguments = $args | % { $_}
14+
& "$CurrentModulePath\webpi\WebpiCmd.exe" $arguments
1615
}
1716

1817
$exportModuleMemberParams = @{

0 commit comments

Comments
 (0)