File tree Expand file tree Collapse file tree 1 file changed +93
-0
lines changed
Expand file tree Collapse file tree 1 file changed +93
-0
lines changed Original file line number Diff line number Diff line change 1+
2+ Pipescript
3+ ----------
4+ ### Synopsis
5+ The Core PipeScript Transpiler
6+
7+ ---
8+ ### Description
9+
10+ The Core PipeScript Transpiler.
11+
12+ This will convert various portions in the PowerShell Abstract Syntax Tree from their PipeScript syntax into regular PowerShell.
13+
14+ It will run other converters as directed by the source code.
15+
16+ ---
17+ ### Related Links
18+ * [ .>Pipescript.Function] ( .>Pipescript.Function.md )
19+ * [ .>Pipescript.AttributedExpression] ( .>Pipescript.AttributedExpression.md )
20+ ---
21+ ### Examples
22+ #### EXAMPLE 1
23+ ``` PowerShell
24+ {
25+ function [explicit]ExplicitOutput {
26+ "whoops"
27+ return 1
28+ }
29+ } | .>PipeScript
30+ ```
31+
32+ #### EXAMPLE 2
33+ ``` PowerShell
34+ {
35+ [minify]{
36+ # Requires PSMinifier (this comment will be minified away)
37+ "blah"
38+ "de"
39+ "blah"
40+ }
41+ } | .>PipeScript
42+ ```
43+
44+ #### EXAMPLE 3
45+ ``` PowerShell
46+ .\PipeScript.psx.ps1 -ScriptBlock {
47+ [bash]{param([string]$Message) $message}
48+ }
49+ ```
50+
51+ #### EXAMPLE 4
52+ ``` PowerShell
53+ .\PipeScript.psx.ps1 -ScriptBlock {
54+ [explicit]{1;2;3;echo 4}
55+ }
56+ ```
57+
58+ #### EXAMPLE 5
59+ ``` PowerShell
60+ {
61+ function [ProxyCommand<'Get-Process'>]GetProcessProxy {}
62+ } | .>PipeScript
63+ ```
64+
65+ ---
66+ ### Parameters
67+ #### ** ScriptBlock**
68+
69+ A ScriptBlock that will be transpiled.
70+
71+
72+
73+ | Type | Requried| Postion| PipelineInput |
74+ | -------------------| --------| -------| --------------|
75+ | ``` [ScriptBlock] ``` | true | named | true (ByValue)|
76+ ---
77+ #### ** Transpiler**
78+
79+ One or more transpilation expressions that apply to the script block.
80+
81+
82+
83+ | Type | Requried| Postion| PipelineInput|
84+ | ----------------| --------| -------| -------------|
85+ | ``` [String[]] ``` | false | named | false |
86+ ---
87+ ### Syntax
88+ ``` PowerShell
89+ Pipescript -ScriptBlock <ScriptBlock> [-Transpiler <String[]>] [<CommonParameters>]
90+ ```
91+ ---
92+
93+
You can’t perform that action at this time.
0 commit comments