Update list-headlines.ps1 and list-news.ps1

This commit is contained in:
Markus Fleschutz 2023-08-07 15:11:32 +02:00
parent 72f4252674
commit 16bb5e7fdb
2 changed files with 1 additions and 8 deletions

View File

@ -23,7 +23,7 @@ try {
[xml]$Content = (Invoke-WebRequest -uri $RSS_URL -useBasicParsing).Content
[int]$Count = 0
foreach ($item in $Content.rss.channel.item) {
" $($item.title)"
" $($item.title)"
$Count++
if ($Count -eq $MaxCount) { break }
}

View File

@ -30,13 +30,6 @@ try {
}
$Source = $Content.rss.channel.title
$Date = $Content.rss.channel.pubDate
$Date = $Date -Replace "Mon, ",""
$Date = $Date -Replace "Tue, ",""
$Date = $Date -Replace "Wed, ",""
$Date = $Date -Replace "Thu, ",""
$Date = $Date -Replace "Fri, ",""
$Date = $Date -Replace "Sat, ",""
$Date = $Date -Replace "Sun, ",""
"(by $Source as of $Date)"
exit 0 # success
} catch {