Advertisement
Korn1699

CodeMashCTF2018_11

Jan 14th, 2018
140
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. Other than some manual things to get around the irregularities in the zip file or repository, I ran this.  This was my first PowerShell script, so I wasn't sure how to pad the filename to 4 characters.  I had to manually add 0s, as I got further.
  2.  
  3. function bacon {
  4.    Param ([int] $b)
  5.    if (1 -eq $b) {return}
  6.    Expand-Archive E:\CodeMashCTF11\0$($b)\0$($b-1).zip -DestinationPath E:\CodeMashCTF11\
  7.    cd ../0$($b-1)
  8.    git checkout -f
  9.    return bacon -b ($b-1)
  10. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement