Welcome to the Chocolatey Community Package Repository! The packages found in this section of the site are provided, maintained, and moderated by the community.
Moderation
Every version of each package undergoes a rigorous moderation process before it goes live that typically includes:
- Security, consistency, and quality checking
- Installation testing
- Virus checking through VirusTotal
- Human moderators who give final review and sign off
More detail at Security and Moderation.
Organizational Use
If you are an organization using Chocolatey, we want your experience to be fully reliable. Due to the nature of this publicly offered repository, reliability cannot be guaranteed. Packages offered here are subject to distribution rights, which means they may need to reach out further to the internet to the official locations to download files at runtime.
Fortunately, distribution rights do not apply for internal use. With any edition of Chocolatey (including the free open source edition), you can host your own packages and cache or internalize existing community packages.
Disclaimer
Your use of the packages on this site means you understand they are not supported or guaranteed in any way. Learn more...

Downloads:
391,462
Downloads of v 20150916.0.1:
2,320
Last Update:
22 Nov 2015
Package Maintainer(s):
Software Author(s):
- Alexpux
- martell
- mingwandroid
- niXman
Tags:
msys2 msys cygwin mingw w64 gnu linux unix posix arch pacman bash makepkg gcc cmd clink powershell posh- Software Specific:
- Software Site
- Software Source
- Software License
- Software Docs
- Package Specific:
- Package Source
- Package outdated?
- Package broken?
- Contact Maintainers
- Contact Site Admins
- Software Vendor?
- Report Abuse
- Download

MSYS2
This is not the latest version of MSYS2 available.
- Software Specific:
- Software Site
- Software Source
- Software License
- Software Docs
- Package Specific:
- Package Source
- Package outdated?
- Package broken?
- Contact Maintainers
- Contact Site Admins
- Software Vendor?
- Report Abuse
- Download
Downloads:
391,462
Downloads of v 20150916.0.1:
2,320
Maintainer(s):
Software Author(s):
- Alexpux
- martell
- mingwandroid
- niXman
Edit Package
To edit the metadata for a package, please upload an updated version of the package.
Chocolatey's Community Package Repository currently does not allow updating package metadata on the website. This helps ensure that the package itself (and the source used to build the package) remains the one true source of package metadata.
This does require that you increment the package version.
MSYS2 20150916.0.1
This is not the latest version of MSYS2 available.
Some Checks Have Failed or Are Not Yet Complete
1 Test Passing and 1 Failing Test
To install MSYS2, run the following command from the command line or from PowerShell:
To upgrade MSYS2, run the following command from the command line or from PowerShell:
To uninstall MSYS2, run the following command from the command line or from PowerShell:
NOTE: This applies to both open source and commercial editions of Chocolatey.
1. Ensure you are set for organizational deployment
Please see the organizational deployment guide
2. Get the package into your environment-
Open Source or Commercial:
- Proxy Repository - Create a proxy nuget repository on Nexus, Artifactory Pro, or a proxy Chocolatey repository on ProGet. Point your upstream to https://chocolatey.org/api/v2. Packages cache on first access automatically. Make sure your choco clients are using your proxy repository as a source and NOT the default community repository. See source command for more information.
- You can also just download the package and push it to a repository Download
-
Open Source
- Download the Package Download
- Follow manual internalization instructions
-
Package Internalizer (C4B)
- Run
choco download msys2 --internalize --version=20150916.0.1 --source=https://chocolatey.org/api/v2
(additional options) - Run
choco push --source="'http://internal/odata/repo'"
for package and dependencies - Automate package internalization
- Run
3. Enter your internal repository url
(this should look similar to https://chocolatey.org/api/v2)
4. Choose your deployment method:
choco upgrade msys2 -y --source="'STEP 3 URL'" [other options]
See options you can pass to upgrade.
See best practices for scripting.
Add this to a PowerShell script or use a Batch script with tools and in places where you are calling directly to Chocolatey. If you are integrating, keep in mind enhanced exit codes.
If you do use a PowerShell script, use the following to ensure bad exit codes are shown as failures:
choco upgrade msys2 -y --source="'STEP 3 URL'"
$exitCode = $LASTEXITCODE
Write-Verbose "Exit code was $exitCode"
$validExitCodes = @(0, 1605, 1614, 1641, 3010)
if ($validExitCodes -contains $exitCode) {
Exit 0
}
Exit $exitCode
- name: Ensure msys2 installed
win_chocolatey:
name: msys2
state: present
version: 20150916.0.1
source: STEP 3 URL
See docs at https://docs.ansible.com/ansible/latest/modules/win_chocolatey_module.html.
Coming early 2020! Central Managment Reporting available now! More information...
chocolatey_package 'msys2' do
action :install
version '20150916.0.1'
source 'STEP 3 URL'
end
See docs at https://docs.chef.io/resource_chocolatey_package.html.
Chocolatey::Ensure-Package
(
Name: msys2,
Version: 20150916.0.1,
Source: STEP 3 URL
);
Requires Otter Chocolatey Extension. See docs at https://inedo.com/den/otter/chocolatey.
cChocoPackageInstaller msys2
{
Name = 'msys2'
Ensure = 'Present'
Version = '20150916.0.1'
Source = 'STEP 3 URL'
}
Requires cChoco DSC Resource. See docs at https://github.com/chocolatey/cChoco.
package { 'msys2':
provider => 'chocolatey',
ensure => '20150916.0.1',
source => 'STEP 3 URL',
}
Requires Puppet Chocolatey Provider module. See docs at https://forge.puppet.com/puppetlabs/chocolatey.
salt '*' chocolatey.install msys2 version="20150916.0.1" source="STEP 3 URL"
See docs at https://docs.saltstack.com/en/latest/ref/modules/all/salt.modules.chocolatey.html.
5. If applicable - Chocolatey configuration/installation
See infrastructure management matrix for Chocolatey configuration elements and examples.
Private CDN cached downloads available for licensed customers. Never experience 404 breakages again! Learn more...
This package was approved by moderator ferventcoder on 22 Dec 2015.
From https://sourceforge.net/p/msys2/wiki/MSYS2%20introduction/ :
"MSYS2 is an independent rewrite of MSYS, based on modern Cygwin (POSIX compatibility layer) and MinGW-w64 with the aim of better interoperability with native Windows software."
You should read the full official introduction before using MSYS2.
Chocolatey MSYS2 is not affiliated with the MSYS2 project and does not include a copy of MSYS2. It just automatically downloads and installs MSYS2 and adds some extra tools for better integration into CMD shell (and PowerShell in future releases).
NOTES
The Chocolatey MSYS2 versioning scheme uses the current MSYS2 archive version as first component and tracks further changes in the Chocolatey package with the second and third component.
Chocolatey MSYS2 automatically installs either 32bit or 64bit MSYS2. It does NOT work with choco install -x86
(forced 32bit installation) under 64bit Windows. There is usually no need to install a 32bit MSYS2 under 64bit Windows, because MSYS2 always contains a MINGW32 and a MINGW64 environment.
The MSYS2 archive will be extracted to Chocolatey's BinRoot (usually C:\Tools\). The 32bit variant uses an msys32\ root folder and the 64bit variant uses msys64\ respectively. The MSYS2 root folder will be appended to %PATH%
. It contains the msys2_shell.bat, mingw32_shell.bat, and mingw64_shell.bat scripts. No bin\ folders will be added to %PATH%
. After unpacking, MSYS2 will be automatically initialized and updated with Pacman according to the official instructions.
MSYS2 itself will not be removed on uninstalling the Chocolatey package and will not be downloaded and extracted again (even if the MSYS2 archive version has changed) on updating or reinstalling the Chocolatey package. The existing MSYS2 will just be updated with Pacman.
Chocolatey MSYS2 offers an extra msystem.bat script in its package folder (which will also be appended to %PATH%
). The script can be used to activate and switch MSYS, MINGW32, and MINGW64 environments inside a CMD shell without running Bash. It will prepend the appropriate bin\ folders to %PATH%
. MSYS mode additionally provides bash.bat and pacman.bat wrapper scripts and according auto-completion scripts for Clink. Call msystem /?
after installation or look at the top of the script file for more details. These extra features and even more (like better integration with other shell environments, a better bash.bat, and more wrapper scripts for tools like makepkg
, ..., and an according PowerShell module) will be moved from the Chocolatey MSYS2 package to separate projects, which will then be installable as MSYS2 packages, of course auto-installed by Chocolatey MSYS2 :)
@echo off
REM Chocolatey MSYS2
REM
REM Copyright (C) 2015 Stefan Zimmermann <[email protected]>
REM
REM Licensed under the Apache License, Version 2.0
setlocal
set MSYSTEM=MSYS
if "%~1" == "" (
start bash.exe --login
) else (
bash.exe --login %*
)
endlocal
@echo off
REM Chocolatey MSYS2
REM
REM Copyright (C) 2015 Stefan Zimmermann <[email protected]>
REM
REM Licensed under the Apache License, Version 2.0
%~dp0\bash.bat -c "pacman --color auto %*"
@echo off
REM Chocolatey MSYS2
REM
REM Copyright (C) 2015 Stefan Zimmermann <[email protected]>
REM
REM Licensed under the Apache License, Version 2.0
if "%~1" == "/?" (
echo Activates an MSYS2 environment inside a CMD shell,
echo either in MSYS or MINGW32 or MINGW64 mode,
echo by prepending the relevant MSYS2 bin\ paths to %%PATH%%.
echo.
echo MSYSTEM [MSYS ^| MINGW32 ^| MINGW64]
echo.
echo The MINGW modes do NOT include the MSYS mode bin\ paths.
echo.
echo In MSYS mode, an additional path containing wrapper scripts
echo for BASH and PACMAN is prepended to %%PATH%%.
echo.
echo The root directory of the MSYS2 installation
echo ^(usually C:\path\to\msys32 or ...\msys64^)
echo must be defined in %%MSYS2_ROOT%% or must be in %%PATH%%.
echo.
echo After successful activation,
echo the environment name will be stored in %%MSYS2_SYSTEM%%
echo and an according ^<MSYS^> or ^<MINGW32^> or ^<MINGW64^> tag
echo will be prepended to %%PROMPT%%.
echo.
echo Call MSYSTEM without an argument
echo to show the currently active MSYS2 environment.
echo.
echo Call MSYSTEM /D to deactivate an MSYS2 environment.
echo.
echo Be careful when using MSYSTEM together with other shell environments
echo ^(like virtual Python environments, etc...^).
echo Due to %%PATH%% changes,
echo the precedence of commands with same names also changes.
echo Future versions of MSYSTEM will try to automatically avoid conflicts
echo with certain other environment types.
echo.
echo Call MSYSTEM /I with any of the following specifiers
echo to install MSYS2 features into certain shell extension frameworks.
echo.
echo Install CLINK auto-completion for MSYSTEM and PACMAN with:
echo.
echo MSYSTEM /I CLINK [clink settings directory]
echo.
echo If no CLINK settings directory is given,
echo MSYSTEM will try to automatically find it.
exit /b 0
)
if "%~1" == "" (
REM only show info and exit
if "%MSYS2_SYSTEM%" == "" (
echo No active MSYS2 environment.
exit /b 1
)
echo %MSYS2_SYSTEM%
exit /b 0
)
REM --------------------------------------------------------------------------
REM Handle flags
if /i "%~1" == "/D" (
REM deactivate MSYS2 environment
set MSYS2_SYSTEM=
goto prepare
)
if /i "%~1" == "/I" (
REM install MSYS2 features into CMD shell extension frameworks
goto install
)
REM --------------------------------------------------------------------------
REM Check for valid MSYS2 environment name and set %MSYS2_SYSTEM% accordingly
for %%M in (MSYS MINGW32 MINGW64) do if /i "%~1" == "%%M" (
set MSYS2_SYSTEM=%%M
goto prepare
)
echo Invalid argument '%~1'. Call MSYSTEM /? for help.
exit /b 1
REM --------------------------------------------------------------------------
REM Check system and create variables for MSYS2 (de)activation
:prepare
if "%MSYS2_ROOT%" == "" (
REM try to find MSYS2 root directory in %PATH%
for %%S in (msys2_shell.bat) do (
set "MSYS2_ROOT=%%~dp$PATH:S"
REM %MSYS2_ROOT% would not be set in current context w/o goto
REM (that often discussed strange set-in-for-loop behavior...)
goto checkRoot
)
:checkRoot
if "%MSYS2_ROOT%" == "" (
echo Can't determine MSYS2 root directory.
echo No %%MSYS2_ROOT%% defined and not in %%PATH%%.
set MSYS2_SYSTEM=
exit /b 1
)
REM remove trailing \
set "MSYS2_ROOT=%MSYS2_ROOT:~0,-1%"
)
if not exist "%MSYS2_ROOT%\" (
echo %%MSYS2_ROOT%% '%MSYS2_ROOT%' does not exist or is not a directory.
set MSYS2_SYSTEM=
exit /b 1
)
REM construct MSYS2 and MINGW32/64 bin paths
set "MSYS2_PATH=%MSYS2_ROOT%\usr\local\bin;%MSYS2_ROOT%\usr\bin;%MSYS2_ROOT%\bin"
set "MSYS2_MINGW32_PATH=%MSYS2_ROOT%\mingw32\bin"
set "MSYS2_MINGW64_PATH=%MSYS2_ROOT%\mingw64\bin"
REM --------------------------------------------------------------------------
REM Always deactivate current MSYS2 environment before activating a new one
:deactivate
REM remove any existing MSYS2 and MINGW32/64 bin paths from %PATH%
call set "PATH=%%PATH:%MSYS2_PATH%;=%%"
call set "PATH=%%PATH:%MSYS2_MINGW32_PATH%;=%%"
call set "PATH=%%PATH:%MSYS2_MINGW64_PATH%;=%%"
REM and also remove the extra MSYS tool wrapper scripts path
call set "PATH=%%PATH:%~dp0msys;=%%"
REM remove any <MSYS> or <MINGW32/64> tags from %PROMPT%
REM (use temporary %_msysPrompt% to avoid too many %PROMPT% changes,
REM which can result in strange shell behavior)
set _cleanPrompt=%PROMPT:$LMSYS$G$S=%
set _cleanPrompt=%_cleanPrompt:$LMINGW32$G$S=%
set _cleanPrompt=%_cleanPrompt:$LMINGW64$G$S=%
REM check if only deactivation requested (via MSYSTEM /D)
if "%MSYS2_SYSTEM%" == "" (
prompt %_cleanPrompt%
set _cleanPrompt=
exit /b 0
)
REM --------------------------------------------------------------------------
:activate
REM prepend MSYS2 bin paths and/or MINGW32/64 bin paths to %PATH%
if "%MSYS2_SYSTEM%" == "MSYS" (
REM also prepend the extra MSYS tool wrapper scripts path
set "PATH=%~dp0msys;%MSYS2_PATH%;%PATH%"
)
if "%MSYS2_SYSTEM%" == "MINGW32" (
set "PATH=%MSYS2_MINGW32_PATH%;%PATH%"
)
if "%MSYS2_SYSTEM%" == "MINGW64" (
set "PATH=%MSYS2_MINGW64_PATH%;%PATH%"
)
REM prepend the appropriate <MSYS> or <MINGW32/64> tag to %PROMPT%
prompt $L%MSYS2_SYSTEM%$G$S%_cleanPrompt%
set _cleanPrompt=
exit /b 0
REM --------------------------------------------------------------------------
REM Install MSYS2 features into CMD shell extension frameworks
:install
if "%2" == "" (
echo Missing specifier. Call MSYSTEM /? for help.
exit /b 1
)
if /i "%2" == "clink" goto clink
REM --------------------------------------------------------------------------
REM Install MSYS2 auto-completion features into CLINK
:clink
setlocal EnableDelayedExpansion
if /i "%~3" == "" (
REM no clink settings dir given ==> try to find
set "clinkDir=%localappdata%\clink"
if not exist "!clinkDir!\" (
echo Could not find CLINK settings directory.
echo Please provide it as additional argument.
exit /b 1
)
) else (
if not exist "%~3\" (
echo '%~3' does not exist or is not a directory.
exit /b 1
)
set "clinkDir=%~3"
)
set nl=^
set "root=%~dp0"
REM remove trailing \
set "root=%root:~0,-1%"
REM create a LUA script that loads all auto-completion scripts from .\clink\
set msysLua= !nl!^
local root = "%root:\=\\%" !nl!^
local scripts = {} !nl!^
local p = io.popen("dir /b " .. root .. "\\clink\\*.lua") !nl!^
for file in p:lines() do !nl!^
table.insert(scripts, file) !nl!^
end !nl!^
if p:close() then !nl!^
for _, file in next, scripts do !nl!^
dofile(root .. "\\clink\\" .. file) !nl!^
end !nl!^
end !nl!^
echo Writing '%clinkDir%\msys2.lua'
echo !msysLua! > %clinkDir%\msys2.lua
endlocal
# Chocolatey MSYS2
#
# Copyright (C) 2015 Stefan Zimmermann <[email protected]>
#
# Licensed under the Apache License, Version 2.0
$ErrorActionPreference = 'Stop';
$packageName = 'msys2'
$url = 'http://repo.msys2.org/distrib/i686/msys2-base-i686-20150916.tar.xz'
$checksum = 'c0f87ca4e5b48d72c152305c11841551029d4257'
$checksumType = 'SHA1'
$url64 = 'http://repo.msys2.org/distrib/x86_64/msys2-base-x86_64-20150916.tar.xz'
$checksum64 = 'abc08265b90f68e8f68c74e833f42405e85df4ee'
$checksumType64 = 'SHA1'
$toolsDir = Split-Path -parent $MyInvocation.MyCommand.Definition
$packageDir = Split-Path -parent $toolsDir
Write-Host "Adding '$packageDir' to PATH..."
Install-ChocolateyPath $packageDir
$osBitness = Get-ProcessorBits
$binRoot = Get-BinRoot
# MSYS2 zips contain a root dir named msys32 or msys64
$msysName = 'msys' + $osBitness
$msysRoot = Join-Path $binRoot $msysName
if (Test-Path $msysRoot) {
Write-Host "'$msysRoot' already exists and will only be updated."
}
else {
Write-Host "Installing to '$msysRoot'"
Install-ChocolateyZipPackage $packageName $url $binRoot $url64 `
-checksum $checksum -checksumType $checksumType `
-checksum64 $checksum64 -checksumType64 $checksumType64
# check if .tar.xz was only unzipped to tar file
# (shall work better with newer choco versions)
$tarFile = Join-Path $binRoot msys2Install
if (Test-Path $tarFile) {
Get-ChocolateyUnzip $tarFile $binRoot
Remove-Item $tarFile
}
}
Write-Host "Adding '$msysRoot' to PATH..."
Install-ChocolateyPath $msysRoot
# Finally initialize and upgrade MSYS2 according to https://msys2.github.io
Write-Host "Initializing MSYS2..."
$msysShell = Join-Path $msysRoot msys2_shell.bat
Start-Process -Wait $msysShell -ArgumentList '-c', exit
$command = 'pacman --noconfirm --needed -Sy bash pacman pacman-mirrors msys2-runtime'
Write-Host "Updating system packages with '$command'..."
Start-Process -Wait $msysShell -ArgumentList '-c', "'$command'"
$command = 'pacman --noconfirm -Su'
Write-Host "Upgrading full system with '$command'..."
Start-Process -Wait $msysShell -ArgumentList '-c', "'$command'"
# Chocolatey MSYS2
#
# Copyright (C) 2015 Stefan Zimmermann <[email protected]>
#
# Licensed under the Apache License, Version 2.0
$ErrorActionPreference = 'Stop';
$packageName = 'msys2'
$toolsDir = Split-Path -Parent $MyInvocation.MyCommand.Definition
$packageDir = Split-Path -Parent $toolsDir
if (Get-Command Uninstall-ChocolateyPath -ErrorAction SilentlyContinue) {
Write-Host "Removing '$packageDir' from PATH..."
Uninstall-ChocolateyPath "$packageDir"
} else {
Write-Host "Please remove '$packageDir' manually from PATH.",
"This should work automatically with future 'choco' versions."
}
$osBitness = Get-ProcessorBits
$binRoot = Get-BinRoot
# MSYS2 root dir is named msys32 or msys64
$msysName = "msys$osBitness"
$msysRoot = Join-Path $binRoot $msysName
Write-Host "Not removing '$msysRoot'.",
"Please remove it manually (and also from PATH)",
"when you don't need it anymore."
Log in or click on link to see number of positives.
- msys2.20150916.0.1.nupkg (8312e131b93c) - ## / 56
In cases where actual malware is found, the packages are subject to removal. Software sometimes has false positives. Moderators do not necessarily validate the safety of the underlying software, only that a package retrieves software from the official distribution point and/or validate embedded software against official distribution point (where distribution rights allow redistribution).
Chocolatey Pro provides runtime protection from possible malware.
Version | Downloads | Last Updated | Status |
---|---|---|---|
MSYS2 20210105.0.0 | 12118 | Wednesday, January 6, 2021 | Approved |
MSYS2 20201109.0.0 | 22017 | Saturday, November 14, 2020 | Approved |
MSYS2 20200903.0.0 | 52714 | Friday, September 4, 2020 | Approved |
MSYS2 20200816.0.0 | 11105 | Sunday, August 16, 2020 | Approved |
MSYS2 20200720.0.0 | 12669 | Tuesday, July 21, 2020 | Approved |
MSYS2 20200719.0.0 | 998 | Sunday, July 19, 2020 | Approved |
MSYS2 20200629.0.0 | 8241 | Tuesday, June 30, 2020 | Approved |
MSYS2 20200602.0.0 | 14524 | Wednesday, June 3, 2020 | Approved |
MSYS2 20200522.0.0 | 6967 | Sunday, May 24, 2020 | Approved |
MSYS2 20190524.0.0.20191030 | 86849 | Wednesday, October 30, 2019 | Approved |
MSYS2 20180531.0.0 | 113337 | Friday, June 1, 2018 | Approved |
MSYS2 20161025.0.0 | 8068 | Monday, November 6, 2017 | Approved |
MSYS2 20160719.1.1 | 38265 | Wednesday, October 12, 2016 | Approved |
MSYS2 20160719.1.0 | 652 | Monday, October 10, 2016 | Approved |
MSYS2 20150916.0.1 | 2320 | Sunday, November 22, 2015 | Approved |
MSYS2 20150916.0.0 | 335 | Sunday, September 27, 2015 | Approved |
MSYS2 Copyright (c) 2013, Алексей
This package has no dependencies.
Ground Rules:
- This discussion is only about MSYS2 and the MSYS2 package. If you have feedback for Chocolatey, please contact the Google Group.
- This discussion will carry over multiple versions. If you have a comment about a particular version, please note that in your comments.
- The maintainers of this Chocolatey Package will be notified about new comments that are posted to this Disqus thread, however, it is NOT a guarantee that you will get a response. If you do not hear back from the maintainers after posting a message below, please follow up by using the link on the left side of this page or follow this link to contact maintainers. If you still hear nothing back, please follow the package triage process.
- Tell us what you love about the package or MSYS2, or tell us what needs improvement.
- Share your experiences with the package, or extra configuration or gotchas that you've found.
- If you use a url, the comment will be flagged for moderation until you've been whitelisted. Disqus moderated comments are approved on a weekly schedule if not sooner. It could take between 1-5 days for your comment to show up.