Last change
on this file since 429 was 347, checked in by roby, 4 years ago |
Aggiornamento per compatibilità con php7.4
|
File size:
613 bytes
|
Rev | Line | |
---|
[347] | 1 | # Windows PowerShell Script
|
---|
| 2 | $ErrorActionPreference = "Stop"
|
---|
| 3 |
|
---|
| 4 | # Go to current location
|
---|
| 5 | $CURRENT_FOLDER=(Get-Location)
|
---|
| 6 | Set-Location (Split-Path $MyInvocation.Line -Parent)
|
---|
| 7 |
|
---|
| 8 | # Remove the old generated PDF files
|
---|
| 9 | Remove-Item *.pdf
|
---|
| 10 |
|
---|
| 11 | # Go to the examples folder
|
---|
| 12 | Set-Location ../examples
|
---|
| 13 |
|
---|
| 14 | Get-ChildItem ./ -File | ForEach-Object {
|
---|
| 15 | $PHP_SCRIPT="$_"
|
---|
| 16 | $PDF_FILE="../test/$_" -replace ".php",".pdf"
|
---|
| 17 | Write-Output " - $PHP_SCRIPT > $PDF_FILE"
|
---|
| 18 | php $PHP_SCRIPT > $PDF_FILE
|
---|
| 19 | }
|
---|
| 20 |
|
---|
| 21 | # Go to the test folder to see the result
|
---|
| 22 | Set-Location ../test
|
---|
| 23 | Get-ChildItem
|
---|
| 24 |
|
---|
| 25 | # Restore the current location
|
---|
| 26 | Set-Location $CURRENT_FOLDER
|
---|
Note:
See
TracBrowser
for help on using the repository browser.