Skip to content

Commit 539f5a3

Browse files
StartAutomatingStartAutomating
authored andcommitted
Markdown Template Transpiler - Updating Patterns (Fixes #393, #113)
1 parent 6a8f261 commit 539f5a3

File tree

1 file changed

+18
-3
lines changed

1 file changed

+18
-3
lines changed

PipeScriptSyntax.md

Lines changed: 18 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,10 @@ Functions and Aliases can be defined in a namespace, which can allow all command
7979
You can define a namespaced function by putting the namespace directly before the word function, for example:
8080

8181
~~~PowerShell
82-
Import-
82+
Import-PipeScript {
83+
partial function PartialExample { 1 }
84+
}
85+
~~~
8386

8487
This will become:
8588
~~~PowerShell
@@ -150,7 +153,11 @@ PipeScript tries to make the PowerShell syntax a bit more programmer friendly.
150153
PipeScript supports the use of ==, providing the left hand side is a variable.
151154

152155
~~~PowerShell
153-
Invoke-True
156+
Invoke-PipeScript {
157+
$a = 1
158+
$a == 1
159+
}
160+
~~~
154161

155162
PipeScript also supports the use of ===
156163

@@ -159,5 +166,13 @@ PipeScript also supports the use of ===
159166
PipeScript supports the use of conditional keywords, which can remove a few excess braces from your code.
160167

161168
~~~PowerShell
162-
Invoke-10
169+
Invoke-PipeScript {
170+
$n = 0
171+
while ($true) {
172+
$n++
173+
break if ($n -ge 10)
174+
}
175+
$n
176+
}
177+
~~~
163178

0 commit comments

Comments
 (0)