skeeto / w64devkit

Portable C and C++ Development Kit for x64 (and x86) Windows
The Unlicense
2.99k stars 210 forks source link

[Feature request] Ability to change console title from w64devkit.ini #115

Closed MagicalDrizzle closed 7 months ago

MagicalDrizzle commented 7 months ago

I frequently have both w64devkit and w64devkit-i686 open at the same time, and it can be difficult to check which window belong to which. I propose the ability to configure the console title from the w64devkit.ini file, like this:

;home = ..\home
;home = %HOMEDRIVE%%HOMEPATH%
;title = w64devkit-i686

For now, a workaround I found is to simply change the code that set the console title: SetConsoleTitleW(u"w64devkit-i686");, and recompile.

rmyorston commented 7 months ago

It's possible to set the console title with:

printf "\033]0;w64devkit-i686\007"
skeeto commented 7 months ago

I've personally been using the escape sequence suggested by @rmyorston, but I like the idea of an .ini option as an alternative. The ini-title branch has an implementation I just whipped up, which I'll merge after further testing and review. I encourage you to try it out yourself! You don't even need to build the entire w64devkit to do so, just w64devkit.c.

MagicalDrizzle commented 7 months ago

They works fine for me! Actually with this commit, this may have turned to a "general MinGW launcher", you can put w64devkit.exe and busybox into another mingw "distro", like winlib or llvm-mingw.