File tree Expand file tree Collapse file tree 1 file changed +3
-14
lines changed
Expand file tree Collapse file tree 1 file changed +3
-14
lines changed Original file line number Diff line number Diff line change @@ -9,23 +9,12 @@ function Language.Python {
99 Because Python does not support multiline comment blocks, PipeScript can be written inline inside of multiline string
1010
1111 PipeScript can be included in a Python string that starts and ends with ```{}```, for example ```"""{}"""```
12- . Example
13- .> {
14- $pythonContent = @'
15- """{
16- $msg = "Hello World", "Hey There", "Howdy" | Get-Random
17- @"
18- print("$msg")
19- "@
20- }"""
21- '@
22- [OutputFile('.\HelloWorld.ps1.py')]$PythonContent
23- }
24-
25- .> .\HelloWorld.ps1.py
2612. EXAMPLE
2713 'print("Hello World")' > .\HelloWorld.py
2814 Invoke-PipeScript .\HelloWorld.py
15+ . EXAMPLE
16+ Template.HelloWorld.py -Message "Hi" | Set-Content ".\Hi.py"
17+ Invoke-PipeScript .\Hi.py
2918#>
3019[ValidatePattern (' \.py$' )]
3120param ()
You can’t perform that action at this time.
0 commit comments