No. 37 Vol. 1Wed 01 December 2021Price: 0/0d

WintoLin: Making Windows more like Linux

pointing finger How Did I Do >> Wed 01 December 2021 by Thran >> Last updated 25/06/2022 >>

The market dictates I use Windows for 8 hours each day. There are a few habits I've learnt on Linux, without which using the computer is uncomfortable and tedious. Here are some approximations for Windows offered to anyone else stranded in the same place.

Alt Drag + Alt Resize on Windows

On Linux, Alt Drag and Alt Resizing are very powerful window management features. These are immense conveniences for window management.

Instead of dragging the cursor to the window title bar, it is simply a case of holding Alt and Left Click, then dragging, to move the window. Likewise, to resize, one holds the Alt key and drags the right mouse button. These features are common to many window managers on Linux, such include Fluxbox and Xfce4.

Thankfully there is a Windows utility that has been developed, bringing this functionality to Windows. ~~It is just called Alt Drag. Download it here.~~

Update: Alt Drag has been discontinued and has some bugs on Windows 11. However, there is a maintained fork named AltSnap. The latest release may be downloaded here.

To enable this at every boot, include a shortcut to AltDrag.exe in your Start Menu's Startup folder.

X-Mouse, focus follows mouse

On Windows, it is typical to click a window to give it 'focus', also known as making it active. The tradition with window management in Unix has been that simply pointing at a window makes it active. This saves the effort of a click, making it much quicker to switch window.

As a little-known secret, the Window manager on Windows has supported this ability natively since Windows 95. It can be enabled using TweakUI on old Windows, Aero Tweak on newer Windows, or a simple utility. I used the utility to enable it: X-Mouse Controls.

It is not necessary to include this in Startup since it just sets the Windows registry.

Multiple desktops

This is the ability to have multiple desktops on the same screen, with different windows open on each. It has been a feature on Unix Window Managers since the mid-90s. Finally, the Windows 10 desktop supports this natively. It is enabled through the 'Task View' button, which is beside the Start button. Click 'Task View' then click the Add Desktop button at the top of the screen to add more. I've added three desktops.

Switching desktop is accomplished through Alt + Win + Left/Right key, to jump left/right.

Shell Functions & Shortcuts

On Linux, it is easy to jump to your home directory in the command line. You simply type cd and press enter, and you are home. On Windows, it isn't as easy. You type: cd %USERPROFILE% to get the same.

Naturally, that isn't convenient enough for me. So I wrote a Windows batch file called gh.bat with the following contents:

@echo off

Then I saved it in C:\my_bin and added that folder to the Windows PATH, under System Configuration -> Environment Variables. This means all I type is gh and Enter, then I "go home" to C:\Users\<my_home>. This works very well and is a huge timesaver.

Here is a good tutorial if you want to master Windows Batch Files, aka Command Files. I've written a number of batch files to make using Windows Cmd.exe convenient, these are all placed in the same my_bin folder and may be called any time.

I've also installed ripgrep and vim, to make the Windows command line even more usable. Using cmd.exe + a few well defined scripts and tools is a much more palatable experience than PowerShell.

Remove annoyances

Quite a lot of annoyances exist on Windows 10/11. There is some spyware and there is nagging advertising. It also feels like a fight just to choose your default program to open each file. This hostility would be intolerable, but alas, there is just too much grounded in the Windows ecosystem. It will be some time before an alternative arises to supplant it.

Nonetheless, you can remove some of the annoyances using this wonderful tool: Winaero Tweaker.

You can also disable some of the spying using this guide: Disable Telemetry. But in short, do Winkey + R, type gpedit.msc and press Enter. Go to Computer Configuration > Administrative Templates > Windows Components > Data Collection and Preview Builds. Then edit Allow Diagnostic Data and change it from Not Configured to Disabled.

Also open services.msc and find the service named Connected User Experiences and Telemetry and open its property pane. Click Stop and switch its startup type to Disabled.

These are small steps, and we can't really trust Microsoft, but they at least say they stop the phoning home.

Tags for this writ:

linux, windows, command-line, shell, hacks,

Latest in How Did I Do

If that wasn't enough, see all in How Did I Do (4 total). Back to writ top.