-
-
Save ecki/6725537 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# | |
# This will format http://openantrag.de/api/proposal/ID/gettop/100 JSON files into CSV | |
# | |
$list = @() | |
foreach($file in Get-ChildItem -Filter proposal-*.json .) { | |
$list += ((Get-Content -Encoding UTF8 $file) -join "`n" | ConvertFrom-Json) | |
} | |
# Inspect Result graphically: PS1> $list | Out-GridView | |
# Inspect Possible Columns: PS1> $list | Get-Member | |
# See full Object: PS1> $list | fc -Depth 3 | |
$list | select Key_Representation, Id, Title, CreatedAt, ID_CurrentProposalStep, IsAbuse | ConvertTo-Csv > file.csv |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment