Advertisement
TH_Zoria

daybreak.ps1

May 13th, 2021
383
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.53 KB | None | 0 0
  1. $hactool = "$PSScriptRoot\hactool.exe"
  2. $prodkeys = "$PSScriptRoot\prod.keys"
  3. $firmware = "$PSScriptRoot\Firmware 12.0.2\"
  4. $files = Get-ChildItem $firmware -Filter *.nca
  5. $numfiles = 0
  6. foreach ($file in $files) {
  7. $hacout = & $hactool -k $prodkeys -i $firmware$file | Out-String
  8. if($hacout -like '*Content Type: Meta*') {
  9. Get-Item $firmware$file | Rename-Item -Path $firmware$file -NewName { $_.Name -replace '.nca','.cnmt.nca' }
  10. $numfiles++
  11. }
  12. }
  13. Write-Host "Renamed "$numfiles " ncas"
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement