Last active
December 10, 2023 08:54
-
-
Save zaccb/f57988424df89a35f4dab9fc8b789685 to your computer and use it in GitHub Desktop.
Chocolatey install script
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
:: Install choco .exe and add choco to PATH | |
@powershell -NoProfile -ExecutionPolicy Bypass -Command "iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1'))" && SET "PATH=%PATH%;%ALLUSERSPROFILE%\chocolatey\bin" | |
:: Install all the packages | |
:::: Browsers | |
choco install googlechrome -fy | |
choco install firefox -fy | |
:::: Text editors / IDEs | |
choco install atom -fy | |
choco install sublimetext3 -fy | |
choco install visualstudiocode -fy | |
choco install visualstudio2015community -fy | |
:::: Dev tools | |
choco install git -fy | |
choco install nodejs.install -fy | |
:::: Media | |
choco install vlc -fy | |
:::: Utilities + other | |
choco install 7zip.install -fy | |
choco install dropbox -fy | |
choco install slack -fy | |
choco install office365proplus -fy |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Using upgrade also installs. The following can be run at will to install on a fresh system or upgrade packages on existing.
`@echo off
echo Administrative permissions required. Detecting permissions ...
net session >nul 2>&1
if %errorLevel% == 0 (
ECHO Okay ...
IF EXIST "C:\ProgramData\chocolatey\bin\chocolatey.exe" (
ECHO Chocolatey is already installed ...
choco upgrade chocolatey chocolatey-core.extension -y
) ELSE (
ECHO Installing Chocolatey ...
@PowerShell -NoProfile -ExecutionPolicy Bypass -Command "iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1'))" && SET "PATH=%PATH%;%ALLUSERSPROFILE%\chocolatey\bin"
)
ECHO Checking packages ...
for /F "eol=#" %%G in (packages.txt) do choco upgrade %%G -y
) else (
echo Failure: Current permissions inadequate.
)`
packages.txt:
package_1
package_2
package_3
#ignored_package_4
package_5