Grep this: Microsoft grafts (most) Linux commands onto Windows
Jump to main content
Search
REG AD
OS PLATFORMS
Grep this: Microsoft grafts (most) Linux commands onto Windows
Coreutils serves over 75 Unix commands in Windows and PowerShell command lines
Joab Jackson
Joab<br>Jackson
Published<br>wed 3 Jun 2026 // 20:04 UTC
Steve Ballmer’s darkest fear has come to pass: Linux has worked itself into the deepest innards of Microsoft Windows itself.<br>At the company’s annual Build developer conference this week, Microsoft released coreutils, a Rust-built multi-call binary file for Windows that serves over 75 Unix commands directly in the Windows CMD and PowerShell command lines – including favorites such as cat, ls, grep, and head. They join Linux favorites curl and sudo which were earlier added to the Microsoft command lines.<br>“Grep in full glory is now available for full Windows access,” enthused Microsoft CEO Satya Nadella yesterday during his Build keynote. Grep (Global Regular Expression Print) provides a way to search through all the files in a given space – it’s essential for searching through gargantuan log files for instance. It is one of the many commands memorized by the daily Linux user.
REG AD
REG AD
Behold! Grep on Windows CMD
Microsoft’s stated motivation in evoking Linux powers is an effort to standardize user commands across the multiverse of platforms it supports so that developer scripts work the same way across containers, PowerShell, Macs, the Windows Subsystem for Linux (WSL), and the DOS-era CMD command line.<br>Unix was built on the philosophy of small programs that can be easily piped together to build larger workflows, so that, say, the output of grep can be combined with other material through the cat (concatenate) command. As a result, developers, admins, and now AI agents write scripts that incorporate these commands.
MORE CONTEXT
No longer just a Copilot, Microsoft's AI wants to take the wheel
Windows 11 update preview promises faster launches, puts Task Manager on NPU patrol
OpenBSD 7.9 arrives, a diamond in the rough proud of every sharp edge
Fedora 44 is out – countless versions of it
The adoption is also good news for Linux expats who occasionally work in the Windows CMD: They will no longer need to remember the standard “ls” command for listing the contents doesn’t work in Windows, and that they have to type the DOS-era “dir” command instead. Now both work.
No longer will you need to remember that “dir” and not “ls” works on CMD.
That said, the devil is in the details for many of these ported commands. Several long-time Linux commands conflict with existing CMD and PowerShell commands of the same names, such as date and rmdir. In these cases, the user must suss out which identical command takes precedence, which can depend on the shell, the PATH order, or the alias table if you are using PowerShell.
REG AD
One X poster noted that Coreutils relieves a repeated “frustration of looking up the PowerShell equivalent syntax” for grep. “Useful functionality over ‘not invented here’ is a huge win!” they wrote.<br>One could run Grep before on Windows through third-party packages such as Cygwin, though Coreutils has the speed of native functionality, thanks to its implementation in Rust.<br>Microsoft built Coreutils from the uutils open source effort of rewriting Linux core commands in Rust, for the purposes of memory safety and cross-platform portability. No doubt, it also helped Microsoft that this package was written under the permissive MIT open source license, thereby sidestepping the sticky GNU GPL requirements that so spooked Ballmer.<br>There are some Unix/Linux commands that this project won’t touch, such as dd, the byte-by-byte copying (“Perhaps useful in the future,” the documentation wryly notes). A few other commands – original DOS Sort and Find – were integrated into their Linux equivalents so they would work in both contexts.<br>And because Windows uses ACLs to assign file ownership, rather than POSIX permission bits, none of the Linux permission-setting commands (chcon, chgrp, chmod, chown, chroot, groups) make any sense to Windows, so any scripts changing file permissions still must be massaged (Linus Torvalds created Linux to adhere to the POSIX standards that define the Unix commands).<br>You can download and install Coreutils, which is only about 4.6MB, through CMD WinGet (“winget install Microsoft.Coreutils”). The download is worth it for grep alone, which is the undisputed champion rifling through all the files in an overloaded directory.<br>Bigger fish to fry<br>When Windows was king at Microsoft, Linux was public enemy number one. But times have changed now that Microsoft has larger competitive threats to worry about than open source – namely the frontier AI labs threatening to disrupt the entire enterprise software market.
REG AD
Linux has been, for several years now, the most popular operating system on the company’s Azure cloud service. And last month, few graybeards...