topgrade-rs / topgrade

Upgrade all the things
GNU General Public License v3.0
1.72k stars 116 forks source link

msys2 updates #356

Open Un1q32 opened 1 year ago

Un1q32 commented 1 year ago

I want to suggest a new step

Which tool is this about? Where is its repository?

msys2 uses pacman, by default its not in PATH unless inside the msys2 shell, but the default location is C:\msys64\usr\bin\pacman.exe

Which operating systems are supported by this tool?

Windows

What should Topgrade do to figure out if the tool needs to be invoked?

Check for pacman.exe in path and in the default install location checking for just pacman without the exe extention would work too since windows will sort everything out as long as the file ends in an executable extention like exe, cmd, or bat, so you could just have the same pacman check run on both arch and windows.

Which exact commands should Topgrade run?

same as on arch linux

Un1q32 commented 1 year ago

bump

s34m commented 1 year ago

Bump noted, will be done hopefully soon, I have just too much to do

Un1q32 commented 1 year ago

its worth noting that another common location for pacman is C:\Users\<user>\scoop\apps\msys2\current\usr\bin\pacman.exe for people who install msys2 with scoop

hour-keeper commented 3 months ago

We should use a command like "C:\msys64\usr\bin\bash -lc '/usr/bin/pacman -Syu'", because pacman executes the scripts in the hooks just as it does in arch linux, and a bash started with the --login option will execute these scripts normally.