aboutsummaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
authorGraham Bloice <graham.bloice@trihedral.com>2014-08-19 22:54:08 +0100
committerAnders Broman <a.broman58@gmail.com>2014-08-20 06:24:44 +0000
commit1c10c7b6ed22aca8f83a948e15cd327a709b4b2f (patch)
tree89281ac0a8f089c584efbe9112ac8ac54a16d393 /tools
parent097401c94e1d775f053f79649f11301932c10d31 (diff)
Modified script to not use PS 3.0 constructs
Change-Id: I0a4a738a410f0aece9459852a51d6c96f11aae76 Reviewed-on: https://code.wireshark.org/review/3739 Reviewed-by: Graham Bloice <graham.bloice@trihedral.com> Petri-Dish: Graham Bloice <graham.bloice@trihedral.com> Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com> Reviewed-by: Anders Broman <a.broman58@gmail.com>
Diffstat (limited to 'tools')
-rwxr-xr-xtools/textify.ps14
1 files changed, 2 insertions, 2 deletions
diff --git a/tools/textify.ps1 b/tools/textify.ps1
index c994b8aa75..814555ae6b 100755
--- a/tools/textify.ps1
+++ b/tools/textify.ps1
@@ -80,9 +80,9 @@ foreach ($src_file in Get-ChildItem $SourceFiles) {
$dst_file += ".txt"
}
- $src_modtime = (Get-ItemProperty -Path $src_file).LastWriteTime
+ $src_modtime = (Get-Item $src_file).LastWriteTime
- if (-not (Test-Path $dst_file) -or (Test-Path $dst_file -OlderThan $src_modtime)) {
+ if (-not (Test-Path $dst_file) -or ((Get-Item $dst_file).LastWriteTime -lt $src_modtime)) {
$contents = Get-Content $src_file
[System.IO.File]::WriteAllLines($dst_file, $contents, $no_bom_encoding)
Write-Host "Textified $src_file to $dst_file"