home *** CD-ROM | disk | FTP | other *** search
/ Xentax forum attachments archive / xentax.7z / 11146 / WFPackageParser.7z / WFPackageParser_readme.txt
Encoding:
Text File  |  2016-06-28  |  2.6 KB  |  45 lines

  1. * Pre-compiled PackagesLexer.dll from Deathmax's WFPackageParser project - https://github.com/Deathmax/WFPackageParser/
  2. * Included getdata.ps1 Powershell script to automate the process of using PackagesLexer.dll
  3. (!) The PackagesLexer.dll may require .NET 4.0/4.5
  4. -------------
  5.  
  6. - Extract the compressed folder to anywhere
  7. - Copy Packages.bin and Languages.bin to the newly extracted folder
  8. - Run the Powershell script (getdata.ps1) or open Powershell, navigate to the extracted folder, and run the commands from getdata.ps1 one at a time.
  9.     * You may receive quick closure of the Powershell window. This is NORMAL BEHAVIOR, but it means the script did not run. Default security settings disallow scripts.
  10.         + To resolve, run Powershell as Admin then execute this command: Set-ExecutionPolicy RemoteSigned
  11.             + When asked, enter Y to confirm the new setting. Rerun the script afterwards
  12.  
  13.         + Documentation about the above security: http://www.adminarsenal.com/admin-arsenal-blog/powershell-how-to-write-your-first-powershell-script/
  14.  
  15.  
  16.     (!) If the above is uncomfortable: open a normal Powershell window, navigate to the newly extracted folder, then run these commands one at a time:
  17.  
  18.         $absolutePath= (Get-Item -Path ".\" -Verbose).FullName
  19.         [Reflection.Assembly]::LoadFile($absolutePath+"\PackagesLexer.dll");
  20.         $PackagesLexer= New-Object "PackagesLexer.Packages" ($absolutePath+"\Packages.bin")
  21.         $LanguagesLexer= New-Object "PackagesLexer.Languages" ($absolutePath+"\Languages.bin")
  22.         $PackagesLexer > Packages.txt
  23.         $LanguagesLexer > Languages.txt
  24.  
  25.  
  26.     (!) What are those commands doing?!
  27.  
  28.         $absolutePath= (Get-Item -Path ".\" -Verbose).FullName
  29.             * This is getting the full path name of where you are in Powershell, required for the next three lines.
  30.  
  31.         [Reflection.Assembly]::LoadFile($absolutePath+"\PackagesLexer.dll");
  32.             * Here we manually loading PackagesLexer.dll into Powershell's Assembly "memory"
  33.  
  34.         $PackagesLexer= New-Object "PackagesLexer.Packages" ($absolutePath+"\Packages.bin")
  35.             * Next, load the non-static function of classname: PackagesLexer function:Packages and tell it to use the string "Packages.bin"
  36.  
  37.         $LanguagesLexer= New-Object "PackagesLexer.Languages" ($absolutePath+"\Languages.bin")
  38.             * Then, load the non-static function of classname: PackagesLexer function:Languages and tell it to use the string "Languages.bin"
  39.  
  40.         $PackagesLexer > Packages.txt
  41.             * Execute the Packages function and store the output into Packages.txt within the same folder
  42.  
  43.         $LanguagesLexer > Languages.txt
  44.             * Execute the Languages function and store the output into Languages.txt within the same folder
  45.