Sycnex / Windows10Debloater

Script to remove Windows 10 bloatware.
MIT License
18.13k stars 2.04k forks source link

Script fails when run #9

Closed shufty closed 6 years ago

shufty commented 6 years ago

Multiple errors when running script in Powershell.

PS C:> .\Windows10Debloater.ps1 -Start-Debloat -Remove-Keys -Protect-Privacy -Stop-EdgePDF

Security warning Run only scripts that you trust. While scripts from the internet can be useful, this script can potentially harm your computer. If you trust this script, use the Unblock-File cmdlet to allow the script to run without this warning message. Do you want to run C:\Windows10Debloater.ps1? [D] Do not run [R] Run once [S] Suspend [?] Help (default is "D"): R At C:\Windows10Debloater.ps1:132 char:19

  • ~ The '<' operator is reserved for future use. At C:\Windows10Debloater.ps1:2527 char:24
  • © 2018 © 2018 GitHub</sp ...
  • 
    Unexpected token 'title="0.15683s from unicorn-2504035863-4s1t0">GitHub</span>' in expression or statement.
    Not all parse errors were reported.  Correct the reported errors and try again.
    + CategoryInfo          : ParserError: (:) [], ParseException
    + FullyQualifiedErrorId : RedirectionNotSupported
  • PS C:>

    Sycnex commented 6 years ago

    Hi Shufty,

    The Windows10Debloater.ps1 file does not use any of those parameters, but the Windows10SysPrepDebloater.ps1 file does.

    The parameters that the Windows10SysPrepDebloater.ps1 uses are as follows:

    -SysPrep, -Debloat, and -StopEdgePDF

    Please try again with the other file and let me know how it works.

    Sycnex commented 6 years ago

    Any update on this?

    vaidotaskia commented 6 years ago

    Downloaded script today and got multiple errors.

    PS C:\WINDOWS\system32> f:\Windows10SysPrepDebloater.ps1 -SysPrep -Debloat -StopEdgePDF
    
    Security warning
    Run only scripts that you trust. While scripts from the internet can be useful, this script can potentially harm your computer. If you trust
     this script, use the Unblock-File cmdlet to allow the script to run without this warning message. Do you want to run
    F:\Windows10SysPrepDebloater.ps1?
    [D] Do not run  [R] Run once  [S] Suspend  [?] Help (default is "D"): R
    At F:\Windows10SysPrepDebloater.ps1:132 char:19
    + </a>              </li>
    +                   ~
    The '<' operator is reserved for future use.
    At F:\Windows10SysPrepDebloater.ps1:136 char:19
    + </a>              </li>
    +                   ~
    The '<' operator is reserved for future use.
    At F:\Windows10SysPrepDebloater.ps1:141 char:19
    + </a>              </li>
    +                   ~
    The '<' operator is reserved for future use.
    At F:\Windows10SysPrepDebloater.ps1:146 char:19
    + </a>              </li>
    +                   ~
    The '<' operator is reserved for future use.
    At F:\Windows10SysPrepDebloater.ps1:150 char:19
    + </a>              </li>
    +                   ~
    The '<' operator is reserved for future use.
    At F:\Windows10SysPrepDebloater.ps1:1479 char:227
    + ... g:0;display:inline"><input name="utf8" type="hidden" value="&#x2713;" ...
    +                                                                 ~
    The ampersand (&) character is not allowed. The & operator is reserved for future use; wrap an ampersand in double quotation marks ("&") to
    pass it as part of a string.
    At F:\Windows10SysPrepDebloater.ps1:1482 char:10
    + </form>  </div>
    +          ~
    The '<' operator is reserved for future use.
    At F:\Windows10SysPrepDebloater.ps1:1498 char:24
    +       <li class="mr-3">&copy; 2018 <span title="0.24799s from unicorn ...
    +                        ~
    The ampersand (&) character is not allowed. The & operator is reserved for future use; wrap an ampersand in double quotation marks ("&") to
    pass it as part of a string.
    At F:\Windows10SysPrepDebloater.ps1:1498 char:36
    +       <li class="mr-3">&copy; 2018 <span title="0.24799s from unicorn ...
    +                                    ~
    The '<' operator is reserved for future use.
    At F:\Windows10SysPrepDebloater.ps1:1498 char:42
    + ...  2018 <span title="0.24799s from unicorn-1384281968-3f9rq">GitHub</sp ...
    +                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    Unexpected token 'title="0.24799s from unicorn-1384281968-3f9rq">GitHub</span>' in expression or statement.
    Not all parse errors were reported.  Correct the reported errors and try again.
        + CategoryInfo          : ParserError: (:) [], ParseException
        + FullyQualifiedErrorId : RedirectionNotSupported
    
    vaidotaskia commented 6 years ago

    Yes. Win+X WindowsPowerShell (Admin)

    OS build 16299.251

    On Wed, Mar 7, 2018 at 6:17 PM, Richard Newton notifications@github.com wrote:

    Did you run it as an administrator?

    On Wed, Mar 7, 2018, 7:47 AM vaidotaskia notifications@github.com wrote:

    Downloaded script today and got multiple errors.

    PS C:\WINDOWS\system32> f:\Windows10SysPrepDebloater.ps1 -SysPrep -Debloat -StopEdgePDF

    Security warning Run only scripts that you trust. While scripts from the internet can be useful, this script can potentially harm your computer. If you trust this script, use the Unblock-File cmdlet to allow the script to run without this warning message. Do you want to run F:\Windows10SysPrepDebloater.ps1? [D] Do not run [R] Run once [S] Suspend [?] Help (default is "D"): R At F:\Windows10SysPrepDebloater.ps1:132 char:19

    -

    ~

    The '<' operator is reserved for future use. At F:\Windows10SysPrepDebloater.ps1:136 char:19

    -

    ~

    The '<' operator is reserved for future use. At F:\Windows10SysPrepDebloater.ps1:141 char:19

    -

    ~

    The '<' operator is reserved for future use. At F:\Windows10SysPrepDebloater.ps1:146 char:19

    -

    ~

    The '<' operator is reserved for future use. At F:\Windows10SysPrepDebloater.ps1:150 char:19

    -

    ~

    The '<' operator is reserved for future use. At F:\Windows10SysPrepDebloater.ps1:1479 char:227

    • ... g:0;display:inline"><input name="utf8" type="hidden" value="✓" ...

    ~

    The ampersand (&) character is not allowed. The & operator is reserved for future use; wrap an ampersand in double quotation marks ("&") to pass it as part of a string. At F:\Windows10SysPrepDebloater.ps1:1482 char:10

    -

    ~

    The '<' operator is reserved for future use. At F:\Windows10SysPrepDebloater.ps1:1498 char:24

    -

  • © 2018 © 2018 GitHub' in expression or statement. Not all parse errors were reported. Correct the reported errors and try again. + CategoryInfo : ParserError: (:) [], ParseException + FullyQualifiedErrorId : RedirectionNotSupported — You are receiving this because you commented. Reply to this email directly, view it on GitHub , or mute the thread .
  • — You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/Sycnex/Windows10Debloater/issues/9#issuecomment-371192262, or mute the thread https://github.com/notifications/unsubscribe-auth/Agc7nvVzTDu7q4W926VsBKb0wr89nq8dks5tcAgUgaJpZM4SQRIy .

    sbf- commented 6 years ago
    The '<' operator is reserved for future use.
    At F:\Windows10SysPrepDebloater.ps1:1498 char:42
    + ...  2018 <span title="0.24799s from unicorn-1384281968-3f9rq">GitHub</sp ...
    +                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    Unexpected token 'title="0.24799s from unicorn-1384281968-3f9rq">GitHub</span>' in expression or statement.

    It looks like you downloaded some HTML page instead of the PS1 script

    vaidotaskia commented 6 years ago

    Thanks, it was my mistake. Downloaded html page instead of copy/pasting source to a new file.

    -- Vaidotas

    On Mon, Mar 12, 2018 at 1:01 PM, SBF notifications@github.com wrote:

    The '<' operator is reserved for future use. At F:\Windows10SysPrepDebloater.ps1:1498 char:42

    • ... 2018 GitHub</sp ...
    • 
      Unexpected token 'title="0.24799s from unicorn-1384281968-3f9rq">GitHub</span>' in expression or statement.

    It looks like you downloaded some HTML page instead of the PS1 script

    — You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/Sycnex/Windows10Debloater/issues/9#issuecomment-372270657, or mute the thread https://github.com/notifications/unsubscribe-auth/Agc7ntItIIBskrqhCJNs5KgAikUaJuXIks5tdlWigaJpZM4SQRIy .

    Sycnex commented 6 years ago

    Can I close this if it has been resolved?

    shufty commented 6 years ago

    Yes sorry! I ended up using the other script Windows10SysPrepDebloater.ps1 and it seems to work well! Only problem is that it seems to skip some apps, but that's a different problem I guess. You can close this thanks.