A mirror clone of ScoopInstaller/Install from github
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Chawye Hsu f07395011e
fix(install): Make sure param block at the top of the script
1 year ago
.vscode Initial commit 2 years ago
tests refactor(install): Avoid using write-host (#9) 2 years ago
.editorconfig chore: update editorconfig 2 years ago
.gitattributes Initial commit 2 years ago
.gitignore chore: Add tests 2 years ago
LICENSE Initial commit 2 years ago
PSScriptAnalyzerSettings.psd1 refactor(install): Avoid using write-host (#9) 2 years ago
README.md fix(install): Correct execution policy check (#14) 1 year ago
install.ps1 fix(install): Make sure param block at the top of the script 1 year ago

README.md

Scoop (un)installer

Installation

Prerequisites

  • Windows 7 SP1+ / Windows Server 2008+, Windows 10 recommended
  • PowerShell 5 or later, PowerShell Core included
  • .NET Framework 4.5 or later
  • PowerShell execution policy in Unrestricted/RemoteSigned/ByPass, for example:
    • Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope CurrentUser

Typical Installation

Run this command from a non-admin PowerShell to install scoop with default configuration, scoop will be install to C:\Users\<YOUR USERNAME>\scoop.

iwr -useb 'https://raw.githubusercontent.com/scoopinstaller/install/master/install.ps1' | iex

Advanced Installation

If you want to have an advanced installation. You can download the installer and manually execute it with parameters.

iwr -useb 'https://raw.githubusercontent.com/scoopinstaller/install/master/install.ps1' -outfile 'install.ps1'

To see all configurable parameters of the installer.

.\install.ps1 -?

For example, install scoop to a custom directory, configure scoop to install global programs to a custom directory, and bypass system proxy while installation.

.\install.ps1 -ScoopDir 'D:\Applications\Scoop' -ScoopGlobalDir 'F:\GlobalScoopApps' -NoProxy

Or you can use the legacy method to configure custom directory by setting Environment Variables. (Not Recommended)

$env:SCOOP='D:\Applications\Scoop'
$env:SCOOP_GLOBAL='F:\GlobalScoopApps'
[Environment]::SetEnvironmentVariable('SCOOP_GLOBAL', $env:SCOOP_GLOBAL, 'Machine')
iwr -useb 'https://raw.githubusercontent.com/scoopinstaller/install/master/install.ps1' | iex

For Admin: Installation under the administrator console has been disabled by default for security reason. If you know what you are doing and want to install Scoop as administrator. Please download the installer and manually execute it with the -RunAsAdmin parameter in an elevated console. Here is the example:

iwr -useb 'https://raw.githubusercontent.com/scoopinstaller/install/master/install.ps1' -outfile 'install.ps1'
.\install.ps1 -RunAsAdmin [-OtherParameters ...]

Silent Installation

You can redirect all outputs to Out-Null or a log file to silence the installer. And you can use $LASTEXITCODE to check the installation result, it will be 0 when the installation success.

# Omit outputs
.\install.ps1 [-Parameters ...] | Out-Null
# Or collect logs
.\install.ps1 [-Parameters ...] > install.log
# Get result
$LASTEXITCODE